Code Monkey home page Code Monkey logo

pyimagej's Introduction

PyImageJ: Python wrapper for ImageJ

Build Status

PyImageJ provides a set of wrapper functions for integration between ImageJ and Python. A major advantage of this approach is the ability to combine ImageJ with other tools available from the Python software ecosystem, including NumPy, SciPy, scikit-image, CellProfiler, OpenCV, ITK and more.

Installation

PyImageJ can be installed using conda. Here is how to create and activate a new conda environment holding PyImageJ

conda create -n pyimagej -c conda-forge pyimagej openjdk=8
conda activate pyimagej

For detailed installation instructions and requirements, see Install.md

Usage

The basic usage of PyImageJ is to start up an ImageJ gateway that translates between Python and ImageJ/Java structures. This gateway can point to any official release of ImageJ or to a local installation.

For instructions on how to start up the gateway for various settings see Initialization.md

Once you have your ImageJ gateway, you can start using it. Here is an example of opening an image using ImageJ and displaying it via a convenience function that calls matplotlib:

import imagej
ij = imagej.init()

url_colony = 'https://samples.fiji.sc/new-lenna.jpg' 

# Load the image
lenna = ij.io().open(url_colony)

# Send it to xarray.  Xarray is a package that adds labeled datasets to numpy (http://xarray.pydata.org/en/stable/)
xarray_lenna = ij.py.from_java(lenna)

# Display the image
ij.py.show(xarray_lenna, cmap='gray')

For instructions on how to do certain tasks, see USAGE.md

Getting Help

The Scientific Community Image Forum is the best place to get general help on usage of PyImageJ, ImageJ, and any other image processing tasks. Bugs can be reported to the PyImageJ GitHub issue tracker.

Contributing

All contributions, reports, and ideas are welcome. Contribution is done via pull requests onto the PyImageJ repository.

Most development discussion takes place on the PyimageJ GitHub repository. You can also reach the developers at the imagej gitter.

pyimagej's People

Contributors

ctrueden avatar hadim avatar hanslovsky avatar imagejan avatar kant avatar kkangle avatar lnyng avatar macarse avatar mpinkert avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.