Skip to main content

pyimgal

Python bindings for the imgal image algorithm and processing library. Visit imgal.org for more information.

Installation

pyimgal from PyPI

You can install the pyimgal package from PyPI with:

$ pip install pyimgal

The pyimgal package is compatible with Python >=3.8 and the following architectures.

Operating System Architecture
Linux amd64, aarch64
macOS intel, arm64
Windows amd64

Alternatively, you can install pyimagal from source by building the imgal_python repository. See the next section for instructions.

Build pyimgal from source

To build the pyimgal Python package from source, use the maturin build tool (this requires the Rust toolchain to build the imgal core library). If you're using uv to manage your Python virtual environments (venv) add maturin to your environment and run the maturin develop --release command in the imgal_python directory of the imgal repository with your selected venv activated:

$ source ~/path/to/myenv/.venv/bin/activate
$ (myenv) cd imgal_python
$ maturin develop --release

Alternatively, if you're using conda or mamba you can do the following:

$ cd imgal_python
$ mamba activate myenv
(myenv) $ mamba install maturin
...
(myenv) $ maturin develop --release

This will install pyimgal in the currently active Python environment.

Usage

Using pyimgal

Once imgal_python has been installed in a compatible Python environment, imgal will be available to import. The example below demonstrates how to obtain a colocalization z-score (i.e. colocalization and anti-colocalization strength) using the Spatially Adaptive Colocalization Analysis (SACA) framework. The two number values after the channels are threshold values for channels a and b respectively.

Note: This example assumes you have 3D data (row, col, ch) to perform colocalization analysis and the tifffile package in your environment.

import imgal.colocalization as coloc
from tifffile import imread

# load some data
image = imread("path/to/data.tif")

# slice channels to perform colocalization analysis
ch_a = image[:, :, 0]
ch_b = image[:, :, 1]

# compute colocalization z-score with SACA 2D with 4 parallel threads
zscore = coloc.saca_2d(ch_a, ch_b, 525, 400, threads=4)

# apply Bonferroni correction and compute significant pixel mask
mask = coloc.saca_significance_mask(z_score)

Documentation

Each function in imgal is documented and published on docs.rs.

License

Imgal is a dual-licensed project with your choice of:

Metadata

Release files for pyimgal 0.4.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pyimgal 0.4.0
File Size Uploaded Provenance Actions
pyimgal-0.4.0.tar.gz 112.6 kB With provenance Details for pyimgal-0.4.0.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for pyimgal 0.4.0
File Actions
pyimgal-0.4.0-cp38-abi3-win_amd64.whl CPython 3.8 abi3 Windows x86-64 Details for pyimgal-0.4.0-cp38-abi3-win_amd64.whl
pyimgal-0.4.0-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.8 abi3 Linux glibc 2.17+ x86-64 Details for pyimgal-0.4.0-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
pyimgal-0.4.0-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl CPython 3.8 abi3 Linux glibc 2.17+ ARM64 Details for pyimgal-0.4.0-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
pyimgal-0.4.0-cp38-abi3-macosx_11_0_arm64.whl CPython 3.8 abi3 macOS 11.0+ ARM64 Details for pyimgal-0.4.0-cp38-abi3-macosx_11_0_arm64.whl
pyimgal-0.4.0-cp38-abi3-macosx_10_12_x86_64.whl CPython 3.8 abi3 macOS 10.12+ x86-64 Details for pyimgal-0.4.0-cp38-abi3-macosx_10_12_x86_64.whl

Total release size: 11.6 MB

Release files / pyimgal-0.4.0.tar.gz

Download URL pyimgal-0.4.0.tar.gz
Size 112.6 kB
Tags Source
SHA-256 checksum
How to use checksums
2172c9c17849d6b4e3a7885a4c8e007cddb5021af10d6b60639a76cb528c6f56
BLAKE2b-256 checksum
How to use checksums
2db2852005d14e113c7e12dc74b4b79c35cea91d656a3902a2231921e0f7e838
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 6, 2026.

Transparency log

Release files / pyimgal-0.4.0-cp38-abi3-win_amd64.whl

Download URL pyimgal-0.4.0-cp38-abi3-win_amd64.whl
Size 2.2 MB
Tags CPython 3.8 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
84c63df3b086a21bce5df7d8b37de639b677ff0fb8bac64c9efabcd7f6e5c346
BLAKE2b-256 checksum
How to use checksums
64d0fa76209ec25ba9ded2055744aaea9ffeaadb13b25dfef0efda6485cbed89
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 6, 2026.

Transparency log

Release files / pyimgal-0.4.0-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL pyimgal-0.4.0-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 2.6 MB
Tags CPython 3.8 Linux glibc 2.17+ x86-64 abi3
SHA-256 checksum
How to use checksums
4b4076f0781ce414e7a96828742431a4012143347fcc9223c6afe2b11810f109
BLAKE2b-256 checksum
How to use checksums
05448ab56a76ebd9805a98ffaf1324f739abf8583a25a58164c65a5a2638d143
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 6, 2026.

Transparency log

Release files / pyimgal-0.4.0-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl

Download URL pyimgal-0.4.0-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Size 2.2 MB
Tags CPython 3.8 Linux glibc 2.17+ ARM64 abi3
SHA-256 checksum
How to use checksums
c516cb0b233a202265a34fb50db795353ede1a2218a46500f63ba917c3be0132
BLAKE2b-256 checksum
How to use checksums
6a0371e5fa640359ca723ced7cbb5661a91a937d39b110a99b659e5d14253179
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 6, 2026.

Transparency log

Release files / pyimgal-0.4.0-cp38-abi3-macosx_11_0_arm64.whl

Download URL pyimgal-0.4.0-cp38-abi3-macosx_11_0_arm64.whl
Size 2.1 MB
Tags CPython 3.8 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
c2841c36564d514fce14ca52eae9551f3e21e458b893457de11f7a2f529249b7
BLAKE2b-256 checksum
How to use checksums
5361994d64377435915cade1f2450dc3e282f92ca760330a4d8ede810fd5c8db
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 6, 2026.

Transparency log

Release files / pyimgal-0.4.0-cp38-abi3-macosx_10_12_x86_64.whl

Download URL pyimgal-0.4.0-cp38-abi3-macosx_10_12_x86_64.whl
Size 2.4 MB
Tags CPython 3.8 abi3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
a62309478cf1cf0bd06111412f476fb0195ae2f195994c387b70e4fe65d98d06
BLAKE2b-256 checksum
How to use checksums
11da602a8da5893ec751ae75c133ada304d8209652b046ae0d8fa1969204e06a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 6, 2026.

Transparency log

Security for pyimgal 0.4.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 6 files in this release have been uploaded with provenance metadata.

Select from 6 files

Attestation for pyimgal-0.4.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 6, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page