Skip to main content

Python wrapper for ImageJ

Project description

Python wrapper for ImageJ provides a set of wrapper functions for integration between ImageJ and Python.

It also provides a high-level entry point imagej.IJ for invoking ImageJ Server APIs; see "ImageJ Server" below for details.


- imglyb

Install imglyb using conda install -c hanslovsky imglyb.

Further information regarding imglyb can be found in the imglyb GitHub repository.


In this example, replace /Applications/ with the location of your Fiji installation.

# Spin up ImageJ.
import imagej
ij = imagej.init('/Applications/')

# Import an image with scikit-image.
import skimage
from skimage import io
# NB: Blood vessel image from:
img = io.imread('')
import numpy as np
img = np.mean(img, axis=2)

# Invoke ImageJ's Frangi vesselness op.
vessels = np.zeros(img.shape, dtype=img.dtype)
import imglyb
ij.op().filter().frangiVesselness(imglyb.to_imglib(vessels), imglyb.to_imglib(img), [1, 1], 20)

See also test/ for other examples of usage.

ImageJ Server


- requests
- Pillow

Use pip install -r server_requirements.txt to install requirements for server.

Pillow is required for the imagej.server module's function. In addition, display or xv needs to exist in your system to view the image.


There is a short usage example here.

Project details

Download files

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

Files for imagej, version 0.3.0
Filename, size File type Python version Upload date Hashes
Filename, size imagej-0.3.0-py3-none-any.whl (3.1 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size imagej-0.3.0.tar.gz (4.2 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page