itasc.contact_analysis.quantifiers.nucleus_dynamics¶
Nucleus-dynamics quantifier — the registry adapter over the dynamics core.
The nucleus twin of cell_dynamics: it runs the same label-agnostic
build_track_dynamics() over the nucleus label stack instead of the cell
one, persisting 4_contact_analysis/nucleus_dynamics.h5. Nuclei are
compact, point-like centroids — the robust default for motility / MSD. The
object-key column stays cell_id (a nucleus is nucleus-seeded so it carries
its cell’s shared track id), so the pooling / plotting layer treats it no
differently.
Classes
Quantifies per-nucleus motion (speed, persistence, MSD, collective) from nucleus labels. |
- class itasc.contact_analysis.quantifiers.nucleus_dynamics.NucleusDynamicsQuantifier[source]¶
Bases:
QuantifierQuantifies per-nucleus motion (speed, persistence, MSD, collective) from nucleus labels.
- quantity_id: ClassVar[str] = 'nucleus_dynamics'¶
Stable key; an empty value marks an intermediate (non-registered) base.
- display_name: ClassVar[str] = 'Nucleus dynamics'¶
Human-readable label shown wherever a quantity is selected.
- requires: ClassVar[tuple[str, ...]] = ('nucleus_labels_path',)¶
PositionInputsfield names this quantifier needs to build.
- required_build_params: ClassVar[dict[str, str]] = {'pixel_size_um': 'pixel size (µm/px)', 'time_interval_s': 'frame interval (s)'}¶
Shared build-param keys that must be present and positive for this quantifier to build, mapped to the human label shown in the UI (e.g. cell density needs
{"fov_area_mm2": "FOV area (mm²)"}). The studio greys the metric out — rather than letting the build fail — until they are supplied. Empty for a quantifier that needs no shared param.
- default_output_name: ClassVar[str] = 'nucleus_dynamics.h5'¶
Default artifact file name (relative to a position); empty for an intermediate base that does not persist.
- table_keys: ClassVar[tuple[str, ...]] = ('frame', 'cell_id')¶
The index columns of this quantifier’s
object_table— its natural grain (e.g.("frame", "cell_id")). A non-empty value marks the quantity as aggregated:itasc.contact_analysis.shape_tablespools it across positions into a table named byquantity_id, keyed on these columns. Empty ⇒ not aggregated into an index-keyed table (e.g. contacts). Value columns are namespaced byquantity_idso a later joined view across tables never has colliding names.
- object_table(output_path)[source]¶
A tidy, column-major per-object table for the plotting backend.
At least a
framekey plus a per-object key (e.g.cell_id). ReturnsNonewhen this quantifier produces no per-object table; the plotting backend then skips it.
- compute_object_table(inputs, *, params=None)[source]¶
The pooled tidy table for one position, computed directly from inputs.
A pooled quantifier (one that declares
table_keys) implements this: it returns the same column-major table thatobject_tableused to return after a disk round-trip, but never touches disk.Nonewhen this position yields no rows. Producers (contacts) are not pooled and do not implement it. params carries the shared build knobs (e.g.fov_area_mm2) for the quantifiers that opt in; per-position values (pixel size, frame interval) arrive via inputs.- Return type:
- Parameters:
inputs (PositionInputs)
params (dict | None)