Skip to main content

Whole slide image registration using elastix.

Reason this release was yanked:

Issues with zarr-v3

Project description

image2image-reg

License PyPI Python Version CI codecov

Whole slide image registration using elastix and/or Valis-WSI.

Overview

image2image-reg is a library for whole-slide image registration. It provides a command-line interface for performing registration, transformation and evaluation of whole-slide image registrations. The library is inspired by wsireg and valis. In fact, the registration workflow is a complete rewrite of the wsireg library to provide more flexibility and control over the registration process.

Differences from wsireg

  • [DONE] Registrations are organized into projects. Project is a collection of configuration, logs, visualisations and images. This should provide a more structured way of organizing your images and not cluttering the working directory.
  • [WIP] Registrations can be initialized with affine matrix (to get a good starting point) - this will allow for faster registration and hopefully better results.
  • [WIP] Registrations can be focused on specific region of interest (mask) - while it's possible to do this in wsireg, it's not as straightforward as it should be.
  • [DONE] Better support for point and GeoJSON data.
  • [DONE] Better CLI interface - more structured and easier to use.
  • [DONE] Better logging - more informative and easier to debug.
  • [DONE] Reusable registrations - since all registration data is contained within the project, it's much easier to re-run certain tasks (such as export images) without having to re-run the registration process.

Planned features:

  • [WIP] Better support for Valis registrations.
  • [WIP] Better support for masks.
  • Add better measures and means of testing effectiveness of registration.
  • Add better multi-processing support.
  • Add 3D module for elastiX registrations.

Getting started

The library provides a command-line interface which can be invoked:

i2reg --help

Will generate output like this:

Usage: i2reg [OPTIONS] COMMAND1 [ARGS]... [COMMAND2 [ARGS]...]...

  Launch registration app.

Options:
  --version      Show the version and exit.
  --dev          Flat to indicate that CLI should run in development mode and catch all errors.
  --no_color     Flag to disable colored logs (essential when logging to file).
  -q, --quiet    Minimal output - only errors and exceptions will be shown.
  --debug        Maximum output - all messages will be shown.
  -v, --verbose  Verbose output. This is additive flag so `-vvv` will print `INFO` messages and -vvvv will print
                 `DEBUG` information.
  --log FILE     Write logs to file (specify log path).
  -h, --help     Show this message and exit.

Project:
  new             Create a new project.
  about           Print information about the registration...
  validate        Validate project configuration.
  add-image       Add images to the project.
  add-path        Specify the registration path between the...
  add-attachment  Add attachment image to registered modality.
  add-points      Add attachment points (csv/tsv/txt) to...
  add-shape       Add attachment shape (GeoJSON) to...
  add-merge       Specify how (if) images should be merged.

Execute:
  preprocess  Preprocess images.
  register    Register images.
  clear       Clear project data...
  export      Export images.

Valis:
  valis-init      Initialize Valis configuration file.
  valis-register  Register images using the Valis algorithm.

Utility:
  merge    Export images.
  convert  Convert images to pyramidal OME-TIFF.

Contributing

Contributions are always welcome. Please feel free to submit PRs with new features, bug fixes, or documentation improvements.

git clone https://github.com/vandeplaslab/image2image-reg.git

pip install -e .[dev]

Project details


Download files

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

Source Distribution

image2image_reg-0.2.2.tar.gz (431.9 kB view details)

Uploaded Source

Built Distribution

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

image2image_reg-0.2.2-py3-none-any.whl (158.1 kB view details)

Uploaded Python 3

File details

Details for the file image2image_reg-0.2.2.tar.gz.

File metadata

  • Download URL: image2image_reg-0.2.2.tar.gz
  • Upload date:
  • Size: 431.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for image2image_reg-0.2.2.tar.gz
Algorithm Hash digest
SHA256 60b827241e98275ca01167c2d790f29926cb87fa0ad3d4789f323bfec2fef1f6
MD5 23c84de48de33e602eea4b7546cbd3a2
BLAKE2b-256 03a7d0af264dcd035cf820641b6bef1093505a97f9aae644e76b20b2376bd36b

See more details on using hashes here.

File details

Details for the file image2image_reg-0.2.2-py3-none-any.whl.

File metadata

File hashes

Hashes for image2image_reg-0.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 a348e262fd32e9bd7530b95f69bce971183f0db2d2402d3ce925706f2d1c75a2
MD5 84925db0d2fed34813dee1bae154f9c0
BLAKE2b-256 87e5249797d95ede4cc9544d2c882be1c954a6ac7456b19f5c87dbda74b03dbb

See more details on using hashes here.

Supported by

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