The napari hub is transitioning to a community-run implementation due to launch in June 2025.
Since October 1, 2024, this version is no longer actively maintained and will not be updated. New plugins and plugin updates will continue to be listed.

NuclePhaser

napari-nuclephaser

A Napari plugin to detect and count nuclei on phase contrast images

Workflow step:
Image annotation
Image segmentation

License MIT PyPI Python Version tests napari hub npe2 Copier

A Napari plugin for automated cell nuclei detection, proliferation and population growth analysis, and single-cell tracking in brightfield and fluorescent nuclei timelapse microscopy images.

napari-nuclephaser is an open-source Napari plugin designed for scientists who need to measure cell proliferation rates, analyze population growth, and perform individual cell tracking on timelapse microscopy images. It utilizes Ultralytics YOLO object detection models and obss/sahi sliced inference methods to detect cell nuclei on brightfield and fluorescent images of any size, including large whole slide ones. Learn more with documentation and paper.

Nuclei detection

We trained a series of YOLOv5 and YOLOv11 models to detect nuclei on phase contrast images. It can be used for counting cells or for individual cell tracking (using nuclei detections as tracking markers). Prominent features of this approach are:

  • Napari-nuclephaser plugin includes obss/sahi functionality, allowing detection on images of arbitrary sizes.

Image didn't load

  • YOLO models are fast, providing reasonable inference speed even with CPU.
  • Ability to predict and automatically count nuclei on stacks of images, making it convenient for cell population growth studies and individual cell tracking.
Image didn't load
  • Calibration algorithm that allows measuring accuracy for each specific use case.

Calibration algorithm

Result of object detection model inference is highly dependent on confidence threshold parameter.

Image didn't load

We created several calibration (finding optimal confidence threshold) algorithms that allow adjusting models to specific use cases (cell types, magnifications, illumination settings, cameras etc.):

  • Calibration using known number of objects on an image. Doesn't produce accuracy metrics.
  • Calibration using fluorescent nuclei stain image (for example, DAPI image). Produces accuracy metrics.
  • Calibration using manual annotation of nuclei. Produces accuracy metrics.

Apart from optimal confidence threshold search, these algorithms return accuracy metrics for specific use cases. Given that the calibration image is large, only part of it is used for search of threshold, while the second part is used for evaluation model's accuracy. Accuracy metrics are Mean Absolute Percentage Error (MAPE) and prediction-ground truth scatterplot, which shows how well model performs with different densities of cells.

Learn more about calibration in documentation.

Image didn't load

Cell Proliferation Measurement & Population Growth Analysis

With NuclePhaser you can reconstruct population growth curves from timelapse images of growing cell population by counting number of nuclei on each image. Key features of this approach are:

  • No special equipment, reagents or dyes required, only regular culture plastic and cell growth medium, microscope with mechanical stage and a PC (even without GPU).
  • Accuracy measurement for each specific use case, so you will be sure the tool is working with appropriate precision.
  • Measuring the number of cells, not the area occupied by cells, which can be significantly influenced by spreading/narrowing of cells.
  • Complete reproducibility of results with metadata.txt files saved for each experiment.

Image didn't load

For more detailed information about how NuclePhaser can be used for cell proliferation measurement & population growth analysis, visit our documentation.

Individual cell tracking

NuclePhaser can be used as an assistant for individual cells tracking. This task is extremely difficult, and manual tracking is still the only method with 100% proof against false tracks. With NuclePhaser, you can significantly simplify manual tracking: instead of marking each cell on each image, you can predict nuclei location with NuclePhaser and then correct the result, which is much faster. Learn more in documentation.

Models

Currently only YOLOv5n, YOLOv5s, YOLOv11n and YOLOv11s models, as well as fluorescent nuclei detector YOLOv5n are downloaded automatically with pip install napari-nuclephaser. To use larger models, download them with these links:

Fluorescent nuclei detectors

ModelLink
Fluorescence_v5nDonwload
Fluorescence_v5sDonwload
Fluorescence_v5mDonwload
Fluorescence_v5lDonwload
Fluorescence_v5xDonwload
Fluorescence_v11nDonwload
Fluorescence_v11sDonwload
Fluorescence_v11mDonwload
Fluorescence_v11lDonwload
Fluorescence_v11xDonwload

Brighfield nuclei detectors

ModelLink
Brightfield_v5nDonwload
Brightfield_v5sDonwload
Brightfield_v5mDonwload
Brightfield_v5lDonwload
Brightfield_v5xDonwload
Brightfield_v11nDonwload
Brightfield_v11sDonwload
Brightfield_v11mDonwload
Brightfield_v11lDonwload
Brightfield_v11xDonwload

[!NOTE] Feel free to use the models published here without the plugin!

napari-nuclephaser plugin offers following widgets:

  • Widget for inference on single image. Result can be in the form of points or boxes with or without confidence scores. Automatically returns number of cells in the name of result layer.
  • Widget for inference on stack of images. Optionally can create .csv or .xlsx file at given location with counting results.
  • Widget for calibration using known number of cells.
  • Widget for calibration using fluorescent nuclei image (fluorescent nuclei detection model is used as a perfect predictor).
  • Widget for calibration using manual annotations.
  • Widget for transforming Napari Points layer into Labels layer, which allows turning detection in tracking algorithms-digestible form (in particular, btrack).
  • Widget for counting number of points in Points layer.

Learn more about widgets and their functionality at documentation.

Citation

If you use NuclePhaser in your work, please cite our preprint:

@article {Voloshin2025.05.13.653705,
	author = {Voloshin, Nikita and Putlyaev, Egor and Chechekhina, Elizaveta and Usachev, Vladimir and Karagyaur, Maxim and Bozov, Kirill and Grigorieva, Olga and Tyurin-Kuzmin, Pyotr and Kulebyakin, Konstantin},
	title = {NuclePhaser: a YOLO-based framework for cell nuclei detection and counting in phase contrast images of arbitrary size with support of fast calibration and testing on specific use cases},
	year = {2025},
	doi = {10.1101/2025.05.13.653705},
	URL = {https://www.biorxiv.org/content/early/2025/05/16/2025.05.13.653705},
	eprint = {https://www.biorxiv.org/content/early/2025/05/16/2025.05.13.653705.full.pdf},
	journal = {bioRxiv}
}

Installation

For detailed installation instructions, visit our documentation.

Contributing

Contributions are very welcome. Tests can be run with tox, please ensure the coverage at least stays the same before you submit a pull request.

License

Distributed under the terms of the MIT license, "napari-nuclephaser" is free and open source software

Issues

If you encounter any problems, please file an issue along with a detailed description.

This napari plugin was generated with copier using the napari-plugin-template.

Version:

  • 0.2.2

Last updated:

  • 07 June 2025

First released:

  • 02 April 2025

License:

Supported data:

  • Information not submitted

Plugin type:

GitHub activity:

  • Stars: 2
  • Forks: 0
  • Issues + PRs: 0

Python versions supported:

Operating system:

Requirements:

  • setuptools
  • wheel
  • napari
  • ultralytics
  • yolov5
  • magicgui
  • sahi
  • scikit-image
  • torch
  • pathlib
  • numpy
  • typing
  • pandas
  • openpyxl
  • seaborn
  • opencv-python
  • imagecodecs