f9aea094643fb3240193b0bc0f1908d5b84d82ab,dask_image/ndmeasure/__init__.py,,center_of_mass,#,24
Before Change
input_wt_mtch_sum = []
for i in _pycompat.irange(input.ndim):
sl = input.ndim * [None]
sl[i] = slice(None)
sl = tuple(sl)
input_i = dask.array.arange(input.shape[i], chunks=input.chunks[i])
input_wt = input * input_i[sl]
After Change
// This only matters if index is some array.
index = index.T
type_mapping = collections.OrderedDict([
(("%i" % i), input.dtype) for i in _pycompat.irange(input.ndim)
])
out_dtype = numpy.dtype(list(type_mapping.items()))
default_1d = numpy.full((1,), numpy.nan, dtype=out_dtype)
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 5
Instances
Project Name: dask/dask-image
Commit Name: f9aea094643fb3240193b0bc0f1908d5b84d82ab
Time: 2018-09-30
Author: jakirkham@gmail.com
File Name: dask_image/ndmeasure/__init__.py
Class Name:
Method Name: center_of_mass
Project Name: dask/dask-image
Commit Name: 783c109c591c6a3affc750d29c9d56f86c1ed6cb
Time: 2018-09-29
Author: jakirkham@gmail.com
File Name: dask_image/ndmeasure/_utils.py
Class Name:
Method Name: _ravel_shape_indices
Project Name: luispedro/mahotas
Commit Name: 48fd85aa56d30159279804e253978918a81a5ab4
Time: 2015-06-03
Author: luis@luispedro.org
File Name: mahotas/bbox.py
Class Name:
Method Name: bbox