02bb4ed03e72ddf68e6d1aa986f428baf0afe014,cellprofiler/modules/measuretexture.py,MeasureTexture,run_one,#MeasureTexture#Any#Any#Any#Any#,491

Before Change


        props = skimage.measure.regionprops(labels, pixel_data)
        per_label = [self.run_mahotas(prop, scale, n_directions) for prop in props]
        features = dask.compute(per_label, scheduler="threads")
        features = numpy.array(features)[0].transpose(1,2,0)

        for direction, direction_features in enumerate(features):
            for feature_name, feature in zip(F_HARALICK, direction_features):
                statistics += self.record_measurement(

After Change



        features = numpy.empty((n_directions, 13, len(unique_labels)))

        for index, prop in enumerate(props):
            label_data = prop["intensity_image"]
            try:
                features[:, :, index] = mahotas.features.haralick(
                    label_data, distance=scale, ignore_zeros=True
                )
            except ValueError:
                features[:, :, index] = numpy.nan

        for direction, direction_features in enumerate(features):
            for feature_name, feature in zip(F_HARALICK, direction_features):
                statistics += self.record_measurement(
                    image=image_name,
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 7

Instances


Project Name: CellProfiler/CellProfiler
Commit Name: 02bb4ed03e72ddf68e6d1aa986f428baf0afe014
Time: 2020-08-17
Author: dstirling@broadinstitute.org
File Name: cellprofiler/modules/measuretexture.py
Class Name: MeasureTexture
Method Name: run_one


Project Name: deepchem/deepchem
Commit Name: c96af58e6ab2f85626e51a331e8479da49329f0e
Time: 2017-01-18
Author: joegomes@stanford.edu
File Name: deepchem/models/tensorflow_models/__init__.py
Class Name: TensorflowClassifier
Method Name: predict_proba_on_batch


Project Name: utkuozbulak/pytorch-cnn-visualizations
Commit Name: 3df2eaf74d8f2299ca05e3e98cab5bf89dafc249
Time: 2017-10-24
Author: utku.ozbulak@gmail.com
File Name: cnn_visualisation.py
Class Name:
Method Name: preprocess_image