SkillAgentSearch skills...

Cellpose

a generalist algorithm for cellular segmentation with human-in-the-loop capabilities

Install / Use

/learn @MouseLand/Cellpose
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

<p> <b>Cellpose </b> </p>

<img src="http://www.cellpose.org/static/images/logo.png?raw=True" width="250" title="cellpose" alt="cellpose" align="right" vspace = "50">

Documentation Status tests codecov PyPI version Downloads Downloads Python version Licence: GPL v3 Contributors website Image.sc forum repo size GitHub stars GitHub forks

Cellpose-SAM: cell and nucleus segmentation with superhuman generalization. It can be optimized for your own data, applied in 3D, works on images with shot noise, (an)isotropic blur, undersampling, contrast inversions, regardless of channel order and object sizes.

To learn about Cellpose-SAM read the paper or watch the talk. For info on fine-tuning a model, watch this tutorial talk, and see this example video of human-in-the-loop training. For support, please open an issue.

Please see install instructions below, and also check out the detailed documentation at <font size="4">cellpose.readthedocs.io</font>. The Cellpose-SAM website allows batch processing of images with a free account on Hugging Face.

Example notebooks:

:triangular_flag_on_post: The Cellpose-SAM model is trained on data that is licensed under CC-BY-NC. The Cellpose annotated dataset is also CC-BY-NC.

CITATION

If you use Cellpose-SAM, please cite the Cellpose-SAM paper: Pachitariu, M., Rariden, M., & Stringer, C. (2025). Cellpose-SAM: superhuman generalization for cellular segmentation. <em>bioRxiv</em>.

If you use Cellpose 1, 2 or 3, please cite the Cellpose 1.0 paper:
Stringer, C., Wang, T., Michaelos, M., & Pachitariu, M. (2021). Cellpose: a generalist algorithm for cellular segmentation. <em>Nature methods, 18</em>(1), 100-106.

If you use the human-in-the-loop training, please also cite the Cellpose 2.0 paper:
Pachitariu, M. & Stringer, C. (2022). Cellpose 2.0: how to train your own model. <em>Nature methods</em>, 1-8.

If you use the new image restoration models or cyto3, please also cite the Cellpose3 paper:
Stringer, C. & Pachitariu, M. (2025). Cellpose3: one-click image restoration for improved segmentation. <em>Nature Methods</em>.

Old updates

v3.1+ update (Feb 2025)

  • support for big data contributed by @GFleishman, usage info here
  • new options to improve 3D segmentation like flow3D_smooth and pretrained_model_ortho, more info here
  • GPU-accelerated mask creation in 2D and 3D (benchmarks)
  • better support for Mac Silicon chips (MPS), although new mask creation code not supported by Mac yet

:star2: v3 (Feb 2024) :star2:

Cellpose3 enables image restoration in the GUI, API and CLI (saved to _seg.npy). To learn more...

  • Check out the paper
  • Tutorial talk about the algorithm and how to use it
  • API documentation here

:star2: v2.0 (April 2022) :star2:

Cellpose 2.0 allows human-in-the-loop training of models! To learn more, check out the twitter thread, paper, review, short talk, and the tutorial talk which goes through running Cellpose 2.0 in the GUI and a jupyter notebook. Check out the full human-in-the-loop video. See how to use it yourself in the docs and also check out the help info in the Models menu in the GUI.

Installation

You can install cellpose using conda or with native python if you have python3.8+ on your machine.

Local installation (< 2 minutes)

System requirements

Linux, Windows and Mac OS are supported for running the code. For running the graphical interface you will need a Mac OS later than Yosemite. At least 8GB of RAM is required to run the software. 16GB-32GB may be required for larger images and 3D volumes. The software has been heavily tested on Windows 10 and Ubuntu 18.04 and less well-tested on Mac OS. Please open an issue if you have problems with installation.

Dependencies

cellpose relies on the following excellent packages (which are automatically installed with conda/pip if missing):

Option 1: Installation Instructions with conda

If you have an older cellpose environment you can remove it with conda env remove -n cellpose before creating a new one.

If you are using a GPU, make sure its drivers and the cuda libraries are correctly installed.

  1. Install a miniforge distribution of Python. Note you might need to use an anaconda prompt if you did not add anaconda to the path.
  2. Open an anaconda prompt / command prompt which has conda for python 3 in the path
  3. Create a new environment with conda create --name cellpose python=3.10. We recommend python 3.10, but python 3.9 and 3.11 will also work.
  4. To activate this new environment, run conda activate cellpose
  5. (option 1) To install cellpose with the GUI, run python -m pip install cellpose[gui]. If you're on a zsh server, you may need to use ' ': python -m pip install 'cellpose[gui]'.
  6. (option 2) To install cellpose without the GUI, run python -m pip install cellpose.

To upgrade cellpose

Related Skills

View on GitHub
GitHub Stars2.1k
CategoryDevelopment
Updated13h ago
Forks596

Languages

Python

Security Score

100/100

Audited on Mar 27, 2026

No findings