Divisualisation

Visualize cell tracking errors

  • Benjamin Gallusser

PyPI tests napari hub

A napari plugin to visualise cell-tracking errors, computed via traccuracy, by lifting 2D/3D+time tracks into an interactive 3D "spacetime" view.

🆕 divisualisation is now a fully fledged napari plugin, with a stateful spacetime lifted view that integrates with regular napari workflows.

2D tracking (bacteria) 3D tracking (C. elegans nuclei)

We originally introduced these visualisations to compare our results in Trackastra: Transformer-based cell tracking for live-cell microscopy to other cell tracking algorithms.

Installation

  1. Please install napari as outlined here.

  2. After that, install divisualisation, either:

    • from within napari via Plugins → Install/Uninstall Plugins… (search for "divisualisation"),
    • or from PyPI:
      pip install divisualisation
      
    • or the latest development version from GitHub:
      pip install git+https://github.com/bentaculum/divisualisation.git
      

Note: requires Python ≥ 3.11 and napari ≥ 0.8.

Usage

Open Plugins → divisualisation → Lift tracks & Divisualisation. The widget has two independent workflows, each in its own box:

  • Lift all tracks layers — fold time into a z axis so every tracks layer rises out of the image plane into a 3D "spacetime" cone. Scrub the time slider to sweep through the cone; toggle off to restore the flat view exactly.
  • Divisualisation — assign ground-truth / predicted / FN-edge / FP-edge tracks layers via the role dropdowns (auto-guessed from layer names), Compute edge errors from the GT/predicted tracks plus their labels, and lift with the error colouring. Color division edges draws each layer's parent→daughter edges as coloured tails (napari otherwise draws them in uncolourable white).

Examples

Run in ipython — each loads data into a viewer, adds the tracks and edge-error overlays, and docks the widget:

  • example_2d.py — bacteria (2D+t).
  • example_3d.py — C. elegans nuclei (3D+t, z scaled ×10).
  • example_programmatic_2d.py — fully scripted render (no GUI): build layers, lift with SpacetimeLift, overlay errors with add_edge_error_tracks, capture a napari_animation keyframe video.

Version:

  • 0.1.0

Last updated:

  • 2026-07-23

First released:

  • 2026-07-23

License:

  • MIT

Supported data:

  • Information not submitted

Plugin type:

Open extension:

Save extension:

Python versions supported:

Operating system:

  • Information not submitted

Requirements:

  • napari>=0.8
  • superqt
  • napari-animation
  • magicgui
  • numpy
  • networkx
  • scipy
  • tqdm
  • traccuracy>=0.4.1
  • pytest; extra == "dev"
  • pytest-qt; extra == "dev"
  • ruff; extra == "dev"
  • mypy; extra == "dev"
  • pre-commit; extra == "dev"
  • twine; extra == "dev"
  • build; extra == "dev"
Website by the napari team, original design by CZI.