neuralib.segmentation.stardist.run_2d.StarDist2DOptions
- class neuralib.segmentation.stardist.run_2d.StarDist2DOptions[source]
Bases:
AbstractSegmentationOption- __init__()
Methods
__init__()eval(**kwargs)eval the model in single file or batch files, and save the results
foreach_normalize_image()Normalize the image in batch mode
foreach_raw_image()Load image from a directory and convert to grayscale
ij_roi_output(filepath)Get imageJ/Fiji
.roioutput save pathlaunch_napari([with_widget])Launch napari viewer for stardist results
main([args, parse_only, system_exit])parsing the commandline input args and call
run().new_parser(**kwargs)create an
ArgumentParser.normalize_image()Normalize the image
raw_image()Load image from file and convert to grayscale
run()called after
main()seg_output(filepath)Get output save path
Attributes
parser description.
EPILOGparser epilog.
EX_GROUP_SOURCEUSAGEparser usage.
batch_modeFlag batch mode
directoryimages directory for batch processing
directory_suffixsuffix in batch mode
fileimage file path
file_modeFlag file mode
force_re_evalforce re-evaluate the result
stardist pretrained model
napari_viewview in napari
no_normalizeNOT DO Percentile-based image normalization for eval
Consider only object candidates from pixels with predicted object probability above this threshold.
save_ij_roiif save also the imageJ/Fiji compatible .roi file
- DESCRIPTION: str = 'Run the Stardist model for segmentation'
parser description. Could be override as a method if its content is dynamic-generated.
- model: Literal['2D_versatile_fluo', '2D_versatile_he', '2D_paper_dsb2018', '2D_demo']
stardist pretrained model
- prob_thresh: float
Consider only object candidates from pixels with predicted object probability above this threshold. Seealso: stardist.models.base._predict_instances_generator: prob_thresh
- seg_output(filepath)[source]
Get output save path
- Parameters:
filepath (Path) – filepath for image
- Returns:
output save path
- Return type:
Path