Skip to main content

DINOSim

License: MIT biorxiv PyPI Python Version tests napari hub

DINOSim-simple

A napari plugin for zero-shot image segmentation using DINOv2 vision transformers.


Overview

napari-DINOSim enables zero-shot image segmentation by selecting reference points on an image. The plugin leverages DINOv2's powerful feature extraction capabilities to compute similarity maps and generate segmentation masks.

For detailed information about the widget's functionality, UI elements, and usage instructions, please refer to the Plugin Documentation. A simple example notebook and an advanced notebook are also available for programmatic use, showing how to load/save embeddings and references.

Installation

You can install napari-DINOSim via pip:

pip install napari-dinosim

or from source using conda:

# Clone the repository
git clone https://github.com/AAitorG/napari-DINOSim.git
cd napari-DINOSim

# Create and activate the conda environment
conda env create -f environment.yml
conda activate napari-dinosim

Usage

To launch napari, run the following command in your terminal:

napari

Within the napari interface, go to Plugins > DINOSim Segmentation > DINOSim Widget in the menu bar. You can then:

  1. Drag and drop your image into the napari viewer
  2. Select points on the objects you want to segment
  3. The plugin will automatically generate segmentation masks based on your selections

For more detailed instructions and examples, please refer to our Plugin Documentation.

License

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

Citation

Please note that DINOSim is based on a publication. If you use DINOSim in your research, please be so kind to cite our work:

@article {Gonzalez-Marfil2025dinosim,
    title = {DINOSim: Zero-Shot Object Detection and Semantic Segmentation on Microscopy Images},
    author = {Gonz{\'a}lez-Marfil, Aitor and G{\'o}mez-de-Mariscal, Estibaliz and Arganda-Carreras, Ignacio},
    journal = {bioRxiv},
    publisher = {Cold Spring Harbor Laboratory},
    URL = {https://www.biorxiv.org/content/early/2025/09/22/2025.03.09.642092},
    doi = {10.1101/2025.03.09.642092},
    year = {2025}
}

Contributing

Contributions are very welcome! Tests can be run with tox. Please ensure the test coverage at least stays the same before submitting a pull request.

Issues

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

Release files for napari-dinosim 0.1.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for napari-dinosim 0.1.5
File Size Uploaded
napari_dinosim-0.1.5.tar.gz 41.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for napari-dinosim 0.1.5
File Interpreter ABI Platform
napari_dinosim-0.1.5-py3-none-any.whl Python 3 none any Details

Total release size: 84.2 kB

Release files / napari_dinosim-0.1.5.tar.gz

Download URL napari_dinosim-0.1.5.tar.gz
Size 41.1 kB
Tags Source
SHA-256 checksum
How to use checksums
9c8d5ae823c64d1367165c11371d05a85b57aaf8db25726d8fe29405f2c0b0ef
BLAKE2b-256 checksum
How to use checksums
3b276b53190d152eac63e517e8114ad112045c843197b1fb128b37eb4fbe975d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.11.15

Release files / napari_dinosim-0.1.5-py3-none-any.whl

Download URL napari_dinosim-0.1.5-py3-none-any.whl
Size 43.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
84fb5786c23304034db135d39a157c5e22c78707fc8dacd1fb436c66126dd3a1
BLAKE2b-256 checksum
How to use checksums
29111717b08a19a84d1acf25f844116f987a8c80ed21d5cd686f42d1f2ad2690
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.11.15

Release history Release notifications | RSS feed

This release

0.1.5 This release

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

0.0.8

2 release files

0.0.7

2 release files

0.0.6

2 release files

0.0.5

2 release files

0.0.4

2 release files

0.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page