navigate.model.analysis.boundary_detect.binary_detect
- navigate.model.analysis.boundary_detect.binary_detect(img_data: Union[_Buffer, _SupportsArray[dtype[Any]], _NestedSequence[_SupportsArray[dtype[Any]]], complex, bytes, str, _NestedSequence[complex | bytes | str]], boundary: list, width: int = 1, offset: Optional[Union[_Buffer, _SupportsArray[dtype[Any]], _NestedSequence[_SupportsArray[dtype[Any]]], complex, bytes, str, _NestedSequence[complex | bytes | str]]] = None, variance: Optional[Union[_Buffer, _SupportsArray[dtype[Any]], _NestedSequence[_SupportsArray[dtype[Any]]], complex, bytes, str, _NestedSequence[complex | bytes | str]]] = None)
Perform a binary search for tissue on an image. Return locations of pixels containing tissue.
- Parameters:
img_data (npt.ArrayLike) – Image
boundary (dict) – List of xy pixel positions indicating presence of tissue as values.
width (int) – Width of subimage. Must be smaller than min(image_data.shape[:1])
offset (npt.ArrayLike) – Camera pixel offset map. Same size as image_data.
variance (npt.ArrayLike) – Camera pixel variance map. Same size as image_data.
- Returns:
boundary – List of boundaries of tissue by row of downsampled image.
- Return type:
list