bfio

Simple reading and writing classes for tiled tiffs using Bioformats.


    Authors:

    Learn more:

    Source code:

    Documentation Status PyPI PyPI - Downloads Bower

    This tool is a simplified but powerful interface to Bioformats using jpype for direct access to the library. This tool is designed with scalable image analysis in mind, with a simple interface to treat any image like a memory mapped array.

    Docker containers with all necessary components are available (see Docker Containers section).

    Summary

    Installation

    Setting up Java

    Note: bfio can be used without Java, but only the python and zarr backends will be useable. Only files in tiled OME Tiff or OME Zarr format can be read/written.

    In order to use the Java backend, it is necessary to first install the JDK. The bfio package is generally tested with JDK 8, but JDK 11 and later also appear to work.

    Installing bfio

    The bfio package and the core dependencies (numpy, tifffile, imagecodecs) can be installed using pip:

    pip install bfio

    Additionally, bfio with other dependencies can be installed:

    1. pip install bfio[bioformats] - Adds support for BioFormats/Java. See License for additional information.
    2. pip install bfio[zarr] - Adds support for OME Zarr
    3. pip install bfio[all] - Installs all dependencies.

    Docker

    labshare/polus-bfio-util:2.3.0

    Ubuntu based container with bfio and all dependencies (including Java).

    labshare/polus-bfio-util:2.3.0-imagej

    Same as above, except comes with ImageJ and PyImageJ.

    labshare/polus-bfio-util:2.3.0-tensorflow

    Tensorflow container with bfio isntalled.

    Documentation

    Documentation and examples are available on Read the Docs.

    Versioning

    We use SemVer for versioning. For the versions available, see the tags on this repository.

    Authors

    Nick Schaub (nick.schaub@nih.gov, nick.schaub@labshare.org)

    License

    This project is licensed under the MIT License Creative Commons License - see the LICENSE file for details.

    NOTE

    Bioformats is licensed under GPL, and as a consequence so is the bioformats_jar package. These packages and libraries are installed when using the bfio[bioformats] option.

    Acknowledgments

    • Parts of this code were written/modified from existing code found in tifffile.

    Version:

    • 2.3.0

    Release date:

    • 07 April 2022

    First released:

    • 22 July 2020

    License:

    • MIT

    Supported data:

    • Information not submitted

    GitHub activity:

    • Stars: 6
    • Forks: 3
    • Issues + PRs: 9

    Python versions supported:

    Operating system:

    Requirements:

    • tifffile (>=2021.8.30)
    • imagecodecs (>=2021.2.26)
    • numpy (>=1.20.1)
    • ome-types (>=0.2.10)
    • lxml

    Sign up to receive updates