https://github.com/brisvag/napari-tutorial-euroscipy2025

https://github.com/brisvag/napari-tutorial-euroscipy2025

Science Score: 26.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (16.8%) to scientific vocabulary
Last synced: 9 months ago · JSON representation

Repository

Basic Info
  • Host: GitHub
  • Owner: brisvag
  • Language: Python
  • Default Branch: main
  • Size: 8.79 KB
Statistics
  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • Open Issues: 0
  • Releases: 0
Created 11 months ago · Last pushed 10 months ago
Metadata Files
Readme

README.md

napari fundamentals tutorial

This tutorial goes over the fundamentals of using napari for the interactive analysis of imaging data. It covers how to use layers, how to quickly generate interactive GUI elements for your processing functions, and how to integrate more complex features such as mouse callbacks.

By the end, we will package everything into a working plugin that can be easily shared on PyPI and the napari-hub.

image

Installation instruction

In this tutorial we assume usage of uv for environment management. If you prefer to use conda or pip, then you may use our installation instructions

To setup your workspace:

  1. Install uv (here instruction https://docs.astral.sh/uv/#installation)
  2. Clone (git clone https://github.com/brisvag/napari-tutorial-euroscipy2025.git) or download the repository
  3. Go into the project directory
  4. Execute uv sync
  5. Check if everything works by executing uv run napari. If the application starts your environment is ready!

You may activate the environment by typing (this is not necessary when running commands via uv run ...) * [Linux/MacOs] source .venv/bin/activate * [Windows] venv\Scripts\activate.bat (or venv\Scripts\Activate.ps1 if using PowerShell)

To deactivate, simply execute deactivate.

Tutorial

The tutorial is structured in a few self-contained python script (named 01_* to 08_*) showcasing a typical explorative process where we build a custom napari plugin, with the goal of interactively performing and optimizing a segmentation procedure on some imaging data.

We start from a simple but non-interactive pure python function, and we integrate it step by step with napari, converting it to a GUI widget, customizing it, and adding extra steps.

We end up with two widgets that allow us to interactively find and apply the best parameters for cell segmentation on our sample data.

Finally, we use the napari plugin template to convert our code into a plugin, ready to publish on PyPI and share with the community (for a sneak-peek of the final product, see this repo).

See also

napari from Jupyter notebook

If you want to try out napari from a jupyter notebook, you also need to install jupyterlab:

sh uv sync --group jupyter

and then run it with

sh uv run jupyter lab napari_from_notebook.ipynb

napari-animation

To test out the napari-animation plugin, sync with

sh uv sync --group animation

Useful links

Owner

  • Name: Lorenzo Gaifas
  • Login: brisvag
  • Kind: user
  • Company: @gutsche-lab

PhD student at @gutsche-lab, doing computational stuff with cryo-ET data.

GitHub Events

Total
  • Watch event: 1
  • Member event: 1
  • Push event: 11
  • Pull request event: 2
Last Year
  • Watch event: 1
  • Member event: 1
  • Push event: 11
  • Pull request event: 2

Committers

Last synced: 11 months ago

All Time
  • Total Commits: 6
  • Total Committers: 2
  • Avg Commits per committer: 3.0
  • Development Distribution Score (DDS): 0.167
Past Year
  • Commits: 6
  • Committers: 2
  • Avg Commits per committer: 3.0
  • Development Distribution Score (DDS): 0.167
Top Committers
Name Email Commits
Lorenzo Gaifas b****g@g****m 5
Grzegorz Bokota b****b@g****m 1

Issues and Pull Requests

Last synced: 11 months ago


Dependencies

pyproject.toml pypi
  • napari >=0.6.3
  • pyqt6 >=6.9.1
  • scikit-image >=0.25.2