junkie is a JUpyter NotebooK Image Explorer
Project description
JuNkIE (a JUpyter NotebooK Image Explorer)
Installing JuNkIE
To install JuNkIE, type:
$ python3 -m pip install --no-cache-dir -U junkie-rfglab
JuNkIE can also be installed with conda/miniconda or mamba (keep in mind that mamba is much faster):
$ mamba install -c rodrigofg junkie-rfglab
We do most of the development and testing of JuNkIE in Jupyter Lab, so we recommend using Jupyter Lab.
A note on the Python interpreter
JuNkIE requires that you have Python 3.10 or above installed.
Using JuNkIE
To start, open a notebook and import JuNkIE:
from junkie import junkie
There are a few ways to open an image with JuNkIE:
-
You can open an image with some other package (e.g. scikit-image, opencv, PIL, etc.) and invoke JuNkIE with a numpy ndarray as the parameter:
import skimage.io as skio astack = skio.imread('cells_movie.tif') myim = junkie(astack)
-
You can also specifiy the path to the image that you want to open:
myim = junkie('cells_movie.tif')
-
Or you can indicate a folder that contains an image sequence:
myim = junkie('./slices')
-
If there are image channels split into different files, you can also specify a tuple of strings to distinguish which files in the folder belong to which channel:
myim = junkie('./slices', ('488', '561'))
-
You can use a list of numpy arrays and/or paths to concatenate sideways (i.e. display side-by-side, but all the images must have the same dimensions!!):
myim = junkie([astack, 'cells_movie.tif'])
-
You can combine the list input with the JuNkIE class method read_image to display image channels side-by-side:
myim = junkie([*junkie.read_image('./slices', ('488', '561'))])
JuNkIE has a couple of additional parameters:
-
cmap (str) indicates the color map used to display the image. It defaults to 'gray'. Check here for a list of color maps.
myim = junkie('cells_movie.tif', cmap='viridis')
-
figsize (Tuple[int, int]) specifies the image panel size. The image aspect ratio is maintained. It defaults to (4, 4).
myim = junkie('cells_movie.tif', figsize=(8, 8)
JuNkIE provides access to the standard matplotlib toolbar, and also includes a second toolbar with additional functionality:
icon | function |
---|---|
rotate 90° clockwise | |
flip horizontally | |
flip vertically | |
invert color map | |
hide/show axes | |
continuous/discrete update |
JuNkIE today
As we develop and improve JuNkIE, there may be small changes to the user interface. This is how JuNkIE looks as of today:
Citing JuNkIE
If you use JuNkIE, please cite this repository. We are working on the paper!
Adding functionality onto JuNkIE
If you would like to extend JuNkIE, please check out JuNkIE-picasso, a JuNkIE fork that allows you to define arbitrary image processing pipelines and integrate them into JuNkIE.
Sponsors
We are grateful for the generous support from the following agencies and institutions, which contribute to the development and maintenance of JuNkIE:
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file junkie_rfglab-2024.5.0.tar.gz
.
File metadata
- Download URL: junkie_rfglab-2024.5.0.tar.gz
- Upload date:
- Size: 18.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.13
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0cea03917f415280a8fb295a21db19d229362dde0259b0ba3952f7f4e1aad6b8 |
|
MD5 | 8e85f7a56565b31c72dd2372cd4e0a89 |
|
BLAKE2b-256 | a57322c18bc85d908a9e14d254d4eb992d222ccf518e6c8047abfa75d5c20278 |
File details
Details for the file junkie_rfglab-2024.5.0-py3-none-any.whl
.
File metadata
- Download URL: junkie_rfglab-2024.5.0-py3-none-any.whl
- Upload date:
- Size: 18.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.13
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | bffd94165ef27f160441ac4221e0f0f8e985b60a4a183902fd4297b183e68722 |
|
MD5 | 1a2b46a83372555ecff99c53df46584e |
|
BLAKE2b-256 | 7fa219ffbbcd8d4b497044a488d3e65da306c435235513ae0d5ed86464463376 |