ConcatVoxelFeatures
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 ConcatVoxelFeatures(extractors: Sequence[Mapping[str, Any]], roi: str | None = None, modalities: Sequence[str] = (), expression: str | None = None)[source]
Bases:
objectJoin several voxel feature families side by side for the same voxels.
Needed whenever a study describes voxels by more than one kind of evidence – say raw intensity of one modality next to texture of another. Homogeneous compositions do NOT need this operator: a single family already accepts a modality list, so
concatexists for the genuinely mixed case.Every child must describe the same ROI, so all children share this operator’s
roiand their row order is the ROI’s C order by contract.- Parameters:
extractors – Child specifications as
{"name": ..., "params": {...}}mappings, resolved through the voxel-feature registry in the given order. A child’s ownroiis overridden by this operator’s.roi – Mask key defining the region of interest for every child;
Noneuses the subject’s single mask.modalities – Accepted for configuration compatibility and ignored; each child names the modalities it reads.
expression – The original v0 method expression, carried for provenance when this extractor was reached by config translation.
- Raises:
HABITAPIError – If fewer than two children are given.
- __init__(extractors: Sequence[Mapping[str, Any]], roi: str | None = None, modalities: Sequence[str] = (), expression: str | None = None) None[source]
- __call__(subject: Subject) VoxelFeatureField[source]
Compute and concatenate every child family for one subject.
- Parameters:
subject – Subject providing the images and the ROI mask.
- Returns:
One row per ROI voxel, with every child’s columns side by side.
- Raises:
HABITAPIError – If two children emit the same column name, or a child does not describe every ROI voxel.