Skip to main content

ome-zarr-converters-tools

License PyPI Python Version CI codecov

A Python library that provides shared utilities for building OME-Zarr image converters. It handles tile management, image registration, filtering, validation, and writing OME-Zarr datasets.

Features

  1. Abstraction layer for building OME-Zarr images and HCS plates from microscope metadata and image data
  2. Customizable pipeline for filtering, validating, registering, and tiling images
  3. Python API for building custom converters, with optional Fractal integration for parallel processing
  4. Flexible input: parse tiles from DataFrames or construct them programmatically

Architecture Diagram

OME-Zarr Converters Tools Architecture

Getting Started

Install via pip:

pip install ome-zarr-converters-tools

For converting data stored on S3 (s3:// URLs), install the s3 extra:

pip install "ome-zarr-converters-tools[s3]"

Quickstart

Convert a tiles table (one row per tile: stage position, size, and image file) into a single OME-Zarr image:

import pandas as pd

from ome_zarr_converters_tools import (
    AcquisitionDetails,
    AutoTiling,
    ChannelInfo,
    ConverterOptions,
    OverwriteMode,
    StagePositionCorrections,
    WriterMode,
    build_default_registration_pipeline,
    single_images_from_dataframe,
    tiled_image_creation_pipeline,
    tiles_aggregation_pipeline,
)

acq = AcquisitionDetails(
    channels=[ChannelInfo(channel_label="DAPI")],
    xy_pixel_size=0.65,  # micrometers
    z_spacing=1.0,
)
tiles = single_images_from_dataframe(
    tiles_table=pd.read_csv("tiles.csv"), acquisition_details=acq
)
options = ConverterOptions()
tiled_image = tiles_aggregation_pipeline(
    tiles=tiles, converter_options=options, resource="/path/to/image/files"
)[0]
tiled_image_creation_pipeline(
    zarr_url="/path/to/output.zarr",
    tiled_image=tiled_image,
    registration_pipeline=build_default_registration_pipeline(
        StagePositionCorrections(), AutoTiling()
    ),
    converter_options=options,
    writer_mode=WriterMode.BY_FOV,
    overwrite_mode=OverwriteMode.NO_OVERWRITE,
    resource="/path/to/image/files",
)

See the tutorials for HCS plates, custom image loaders, and Fractal tasks.

Documentation

For detailed documentation, tutorials, and API reference, visit the official documentation.

The documentation includes:

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ome_zarr_converters_tools-1.0.2.tar.gz (27.1 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ome_zarr_converters_tools-1.0.2-py3-none-any.whl (85.5 kB view details)

Uploaded Python 3

File details

Details for the file ome_zarr_converters_tools-1.0.2.tar.gz.

File metadata

File hashes

Hashes for ome_zarr_converters_tools-1.0.2.tar.gz
Algorithm Hash digest
SHA256 1ae0791cf6bac29f8f149cd7691fae1957bf65244e735c9ca6c33e267b01bcc1
MD5 97ac4d977e8a0585d75a909924281abe
BLAKE2b-256 9b77cc36c6af409d753fb347ea0bd2985b5435b292af4793ebb228d8d614b862

See more details on using hashes here.

Provenance

The following attestation bundles were made for ome_zarr_converters_tools-1.0.2.tar.gz:

Publisher: ci.yml on BioVisionCenter/ome-zarr-converters-tools

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file ome_zarr_converters_tools-1.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for ome_zarr_converters_tools-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 93523b2afbdd4d3516069900f1139f6b1f3a86845a12156e7f8eb5e3b8cd90de
MD5 f37a23ec78dd5c42e5cc8601d2a67ad3
BLAKE2b-256 77d83de5f3eb5c724c89dc1769a9e64d32d7370a82d9342a6d22be49ab8e1dc3

See more details on using hashes here.

Provenance

The following attestation bundles were made for ome_zarr_converters_tools-1.0.2-py3-none-any.whl:

Publisher: ci.yml on BioVisionCenter/ome-zarr-converters-tools

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page