SupervoxelFeatureTree

Note

This page is a reference documentation. It only explains the class signature, and not how to use it. Please refer to the Habitat Guide and Python API guide (v2.0) for usage.

class SupervoxelFeatureTree(spec: Spec)[source]

Bases: _FeatureTreeBase

Evaluate a supervoxel-level feature tree into one Supervoxelization.

Children describe the SAME partition (same label_array) with different feature columns; the combiner merges those columns. Statistical leaves (mean / std / percentile) additionally need the subject’s voxel feature field, supplied through bind_fields() by the pipeline before the call.

__init__(spec: Spec) → None[source]
bind_fields(working: VoxelFeatureField | None = None, original: VoxelFeatureField | None = None) → None[source]

Supply the voxel feature fields statistical leaves aggregate from.

Propagates recursively so nested trees and direct statistical leaves both receive the fields. working is the field AFTER the subject-level preprocessing chain (the signal the supervoxelizer partitioned); original is the field BEFORE it, enabling source="original" aggregation.

Parameters:
  • working – Post-preprocessing voxel feature field, or None.

  • original – Pre-preprocessing voxel feature field, or None.

__call__(subject: Subject, partition: Supervoxelization) → Supervoxelization[source]

Compute the composed supervoxel features for one subject.

Parameters:
  • subject – Owning subject.

  • partition – The supervoxel partition to describe.

Returns:

The same regions with the merged feature columns.