make_segments
- petrofit.segmentation.make_segments(image, npixels=None, threshold=3.0)[source]
Segment an image.
- Parameters:
- imagearray like
Input image
- npixelsint
The number of connected pixels, each greater than
threshold, that an object must have to be detected.npixelsmust be a positive integer.- thresholdfloat or array-like
The data value or pixel-wise data values to be used for the detection threshold. A 2D
thresholdmust have the same shape asdata. Seedetect_thresholdfor one way to create athresholdimage.
- Returns: