17568750c85c2cbc3c41b22a4b3498006cd0ed67,dask_ml/utils.py,,check_array,#Any#,89

Before Change


    and passed to scikit-learn"s ``check_array`` with all the additional
    arguments.
    
    accept_dask_array = kwargs.pop("accept_dask_array", True)
    preserve_pandas_dataframe = kwargs.pop("preserve_pandas_dataframe", False)
    accept_dask_dataframe = kwargs.pop("accept_dask_dataframe", False)
    accept_unknown_chunks = kwargs.pop("accept_unknown_chunks", False)
    accept_multiple_blocks = kwargs.pop("accept_multiple_blocks", False)

After Change


            if min(array.chunks[0]) == 0:
                // scikit-learn does not gracefully handle length-0 chunks
                // in some cases (e.g. pairwise_distances).
                chunks2 = tuple(x for x in array.chunks[0] if x != 0)
                array = array.rechunk({0: chunks2})

        // hmmm, we want to catch things like shape errors.
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: dask/dask-ml
Commit Name: 17568750c85c2cbc3c41b22a4b3498006cd0ed67
Time: 2019-10-22
Author: TomAugspurger@users.noreply.github.com
File Name: dask_ml/utils.py
Class Name:
Method Name: check_array


Project Name: stellargraph/stellargraph
Commit Name: 21e91a0334e0b164629a86442fc7ec7131625e22
Time: 2019-09-08
Author: 52440942+geoffj-d61@users.noreply.github.com
File Name: stellargraph/data/explorer.py
Class Name: SampledBreadthFirstWalk
Method Name: run


Project Name: eth-cscs/reframe
Commit Name: 659ebabe13dfebd9449c7eb50eafe108b47d8ab1
Time: 2019-06-05
Author: karakasis@cscs.ch
File Name: reframe/frontend/dependency.py
Class Name:
Method Name: toposort