prevampire.apply_threshold#
- prevampire.prevampire.apply_threshold(img_arr, img_name_list, label='threshli', method='li', print_image=0)[source]#
Apply a thresholding method to a list of images and return segmented images.
- Parameters:
- img_arrlist
A list of NumPy arrays representing the intensified images.
- img_name_listlist
A list of image names corresponding to the arrays.
- labelstr, optional
A label to append to the segmented image names. Defaults to ‘threshli’.
- print_imageint, optional
Number of segmented images to display. Defaults to 0.
- methodstr, optional
The thresholding method to use. Defaults to ‘li’.
- Returns:
- tuple
A tuple containing two elements: - segmented_images : list
A list of segmented images.
- seg_name_listlist
A list of corresponding segmented image names.
- Raises:
- UnequalLengthError
If the lengths of the input arrays are not equal.