Metadata-Version: 2.1
Name: ImmunoViewer
Version: 0.2.2.dev0
Summary: Explore and annotate your multi-channel large TIF files with this user-friendly viewer.
Author-email: David van IJzendoorn <davidvanijzendoorn@gmail.com>
License: Creative Commons Attribution-NonCommercial 4.0 International License
        
        Copyright (c) 2023 David van IJzendoorn
        
        This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.
        
        You are free to:
        - Share — copy and redistribute the material in any medium or format
        - Adapt — remix, transform, and build upon the material
        
        Under the following terms:
        - Attribution — You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
        - NonCommercial — You may not use the material for commercial purposes.
        
        No additional restrictions — You may not apply legal terms or technological measures that legally restrict others from doing anything the license permits.
        
        
Project-URL: Homepage, https://github.com/davidvi/ImmunoViewer
Project-URL: Source, https://github.com/davidvi/ImmunoViewer
Project-URL: Bug Reports, https://github.com/davidvi/ImmunoViewer/issues
Project-URL: Documentation, https://github.com/davidvi/ImmunoViewer
Keywords: big tif,immuno,viewer,annotate,annotation,discover,discovery,image,images,tif,tiff,multi-channel,multi c
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: End Users/Desktop
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE.md
Requires-Dist: click ~=8.1.3
Requires-Dist: contourpy ~=1.0.7
Requires-Dist: cycler ~=0.11.0
Requires-Dist: fonttools ~=4.39.0
Requires-Dist: itsdangerous ~=2.1.2
Requires-Dist: jinja2 ~=3.1.2
Requires-Dist: kiwisolver ~=1.4.4
Requires-Dist: markupsafe ~=2.1.2
Requires-Dist: matplotlib ~=3.7.1
Requires-Dist: numpy ~=1.24.2
Requires-Dist: pillow ~=9.4.0
Requires-Dist: pyparsing ~=3.0.9
Requires-Dist: werkzeug ~=2.2.3
Requires-Dist: watchdog ~=4.0.0
Requires-Dist: aicsimageio ~=4.14.0
Requires-Dist: opencv-python ~=4.7.0
Requires-Dist: gunicorn ~=22.0.0
Requires-Dist: fastapi ~=0.110.2
Requires-Dist: uvicorn ~=0.29.0
Requires-Dist: pydantic-settings ~=2.2.1
Provides-Extra: test
Requires-Dist: pytest >=6.0 ; extra == 'test'
Requires-Dist: mock >=4.0 ; extra == 'test'

# ImmunoViewer

Explore and annotate your multi-channel large TIF files with this user-friendly viewer.

## Table of Contents

* [About ImmunoViewer](#about-immunoviewer)  
* [Installation](#installation)  
    * [Install OpenSlide](#install-openslide)
    * [Install from GitHub](#install-from-github)
    * [Install from pip](#install-from-pip)
* [Usage](#usage)  
    * [Folder structure](#folder-structure)
    * [Generate tiles](#generate-tiles)
    * [Run the viewer](#run-the-viewer)
* [Acknowledgements](#acknowledgements)


## About ImmunoViewer

ImmunoViewer is a convenient tool for viewing scanned TIF files, particularly those generated by the Keyence Immuno Fluorescence scanner. The viewer allows you to add annotations to the images and supports multi-channel images by saving channels as separate big TIF files. You can customize the color and signal intensity for each channel. We welcome your suggestions for additional features.

<img src="https://github.com/davidvi/ImmunoViewer/raw/main/img/screenshot.jpg" height="500">  

## Installation

### Install OpenSlide

ImmunoViewer requires OpenSlide to generate tiled images (not necessary for the viewer). If you use Conda to install ImmunoViewer, it will automatically install OpenSlide.

To install OpenSlide using a Conda environment, run this command:

```bash
conda install -c conda-forge openslide
```

For installation instructions on other operating systems, visit the OpenSlide download page: [OpenSlide](https://openslide.org/download/)

### Install from github

Ensure that you have also installed OpenSlide.

```bash
git clone https://github.com/davidvi/ImmunoViewer.git
cd ImmunoViewer
python setup.py install
```

### Install from pip 

Ensure that you have also installed OpenSlide.

```bash
pip install ImmunoViewer
```

## Usage

### Folder structure

Organize your TIF files in a folder using one of the following structures:

* data_directory/sample_name/sample_file.tif
* data_directory/project_name/sample_name/sample_file.tif
* data_directory/project_name/sample_name/[ch1.tif, ch2.tif, chN.tif]

### Generate tiles

To generate the tiles, execute the following command:

```bash
ImmunoViewerProcess -t [number of threads] [data_directory]
```

### Run the viewer

To start the viewer, run the following command: 

```bash
ImmunoViewerServer -p [port (default is 5000)] -l [IP address (default = 0.0.0.0)] [data_directory]
```

Now you can navigate to http://[IP address]:[port] in your web browser to access ImmunoViewer.

If you leave the IP address to default (0.0.0.0) and the port is exposed to the network other people can also view your slides.  

## Acknowledgements 

The script to tile big TIF files was adapted from the [OpenSlide-python repo](https://github.com/openslide/openslide-python). 
