Skip to content

czitools.metadata_tools.detector #

Detector metadata utilities for CZI files.

Provides CziDetector, which collects detector properties (manufacturer, model, type, pixel size, id) from CZI metadata.

Classes:

  • CziDetector

    Extract detector information from a CZI file.

CziDetector dataclass #

CziDetector(
    czisource: Union[str, PathLike, Box],
    verbose: bool = False,
)

Extract detector information from a CZI file.

This class converts the detector information found under ImageDocument.Metadata.Information.Instrument.Detectors.Detector into parallel lists for each detector attribute. The implementation is defensive: if the Instrument/Detectors block is missing the instance will contain single-element lists with None so callers that expect list-shaped fields keep working.

Attributes:

  • czisource (Union[str, PathLike, Box]) –

    Path/URL string or already-parsed Box with metadata.

  • model, ((name, Id, modeltype, gain, zoom, amplificationgain)) –

    Lists containing values per-detector (may be a single None).

  • verbose (bool) –

    If True, log informational messages while parsing.