ecf62ac20ef561df4265c3d1abd8c59b1e73895f,cellprofiler/modules/threshold.py,Threshold,get_threshold,#Threshold#Any#Any#Any#,745

Before Change


            t_local = t_global * self.threshold_correction_factor.value

            return (
                min(max(t_local, self.threshold_range.min), self.threshold_range.max),
                t_global,
            )

After Change


            )
            return self._correct_global_threshold(orig_threshold), orig_threshold, None

        elif self.threshold_scope.value == TS_GLOBAL or automatic:
            return self.get_global_threshold(image, automatic=automatic)

        elif self.threshold_scope.value == TS_ADAPTIVE:
            return self.get_local_threshold(image)

        else:
            raise ValueError("Invalid thresholding settings")

    def get_global_threshold(self, image, automatic=False):
        image_data = image.pixel_data[image.mask]
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 7

Instances


Project Name: CellProfiler/CellProfiler
Commit Name: ecf62ac20ef561df4265c3d1abd8c59b1e73895f
Time: 2020-06-11
Author: dstirling@broadinstitute.org
File Name: cellprofiler/modules/threshold.py
Class Name: Threshold
Method Name: get_threshold


Project Name: facebookresearch/poincare-embeddings
Commit Name: 5f465041619a63bf1de99c55d1298865bf70fd9e
Time: 2020-01-07
Author: mattle@fb.com
File Name: embed.py
Class Name:
Method Name: async_eval


Project Name: SINGROUP/dscribe
Commit Name: e0d2e4a9c86b057c58989277a19b98e763766f4b
Time: 2018-06-06
Author: lauri.himanen@aalto.fi
File Name: describe/descriptors/elementaldistribution.py
Class Name: ElementalDistribution
Method Name: __init__