juspice.preprocess_module

Image preprocessing for microscopy images.

Provides two interfaces built on OpenCV:

PreprocessingAccessor

Available as spice.preprocess on every SPICEData. Each method changes spice.data in place, records the step in spice.history and returns spice.

ImagePreprocessor

Deprecated stand-alone helper that works on a file path or NumPy array.

Examples

>>> import juspice as jp
>>> spice = jp.load_data("sample.tiff")
>>> spice = spice.preprocess.equalize_histogram().preprocess.normalize()
>>> spice.preprocess.show_image(title="Preprocessed", show_colorbar=True)