spacr.qt.screens.curate

Workflow inputs and outputs

Curate

Correct labels and track assignments while retaining a record of the edits.

Open: Make Masks → Curate.

Inputs and outputs below include conditional alternatives. The guidance and handoff notes say which route applies.

Inputs

  • Microscope images — Source image folder; original files, supported vendor files or imported TIFFs.

  • Label masks — masks/ when retained, or explicitly saved image/mask pairs. Intermediate masks may be removed by cleanup.

  • Linked time-series objects — Tracked labels and frame/object associations from the time-series project, with frame interval and units.

Outputs

  • Label masks — masks/ when retained, or explicitly saved image/mask pairs. Intermediate masks may be removed by cleanup.

  • Linked time-series objects — Tracked labels and frame/object associations from the time-series project, with frame interval and units.

API reference.

Module tutorial.

B12 C7 — the screen where a mask and its tracks get corrected.

A layer viewer with two panels beside it: the brush, and the track surgery. They are on one screen because they are one job. A track breaks because the mask lost the cell for a frame, so the person who joins the track is the person who wants to look at the mask at that frame, and making them two apps would mean two file dialogs and two mental models for one correction.

Everything on this screen is recorded. See spacr.curation for why that is a rule rather than a feature: a hand-edited mask that looks exactly like a segmented one is a reproducibility hole, and the ledger written beside each artefact is what lets a curated dataset be told from a raw one six months later by someone who was not there.

Classes

CurateScreen

Correct a mask by hand and curate its tracks, on the record.

Functions

make_curate_screen(→ CurateScreen)

Build the screen. The factory= for spacr.qt.app.register_app().

register(*[, section, stage, key])

Put Curate in the app registry. Idempotent.

Module Contents

class spacr.qt.screens.curate.CurateScreen(parent=None)[source]

Bases: PySide6.QtWidgets.QWidget

Correct a mask by hand and curate its tracks, on the record.

Parameters:

parent – parent widget.

Build the curation screen and arm its drop zone.

Parameters:

parent – parent widget, or None.

attach_brush(layer, *, artifact: str = '') → spacr.qt.curation_tool.BrushPanel[source]

Put a brush panel over layer. The seam a test goes through.

Parameters:

layer – the labels layer the new BrushPanel edits; any previous brush panel is stopped and removed first.

closeEvent(event) → None[source]

Stop background work and unlink before going away.

Parameters:

event – the Qt close event.

open_mask() → spacr.qt.curation_tool.BrushPanel | None[source]

Load the mask and put a brush on it. Returns the panel.

open_tracks() → bool[source]

Load a tracks CSV into the track panel.

spacr.qt.screens.curate.make_curate_screen(**_kwargs) → CurateScreen[source]

Build the screen. The factory= for spacr.qt.app.register_app().

spacr.qt.screens.curate.register(*, section: str | None = None, stage: str | None = None, key: str = APP_KEY)[source]

Put Curate in the app registry. Idempotent.

Returns:

the registry row, or None when the key was already there.