itk_dreg.base.image_block_interface
¶
Module Contents¶
Classes¶
Status codes indicating the registration outcome from a single block pair. |
|
Header information describing the position of a lazy dask subvolume (block) in voxel space with respect to a parent volume. |
|
Combined header and data access to get a lazy dask volume with respect to a parent volume in voxel space. |
|
Encapsulate result of fixed-to-moving registration over one block pair. |
|
Encapsules pairwise registration result information with contextual information describing how the fixed subimage in registration relates to the greater fixed image. |
|
Encapsulate result of fixed-to-moving registration over all block pairs. |
|
Encapsulate result of fixed-to-moving registration over all block pairs. |
API¶
- class itk_dreg.base.image_block_interface.BlockRegStatus¶
Bases:
enum.IntEnum
Status codes indicating the registration outcome from a single block pair.
TODO: Extend with more granular error codes for
itk-dreg
infrastructure.Initialization
Initialize self. See help(type(self)) for accurate signature.
- SUCCESS¶
0
Registration yielded at least a forward transform result.
- FAILURE¶
1
Registration encountered an unspecified error.
- class itk_dreg.base.image_block_interface.BlockInfo¶
Header information describing the position of a lazy dask subvolume (block) in voxel space with respect to a parent volume.
Accessors are in NumPy order: (K,J,I) where K is slowest, I is fastest
- chunk_index: List[int]¶
None
The chunk position in the greater image volume in terms of chunk counts. For instance, if traversing 2x2x2 volume along the fastest axis first:
the 0th chunk would have chunk index (0,0,0),
the 1st chunk would have chunk index (0,0,1),
the 7th chunk would have chunk index (1,0,0)
- class itk_dreg.base.image_block_interface.LocatedBlock¶
Combined header and data access to get a lazy dask volume with respect to a parent volume in voxel space.
Accessors are in NumPy order: (K,J,I) where K is slowest, I is fastest
- loc: itk_dreg.base.image_block_interface.BlockInfo¶
None
The location of the block relative to the parent image voxel array.
- arr: dask.array.core.Array¶
None
The dask volume for lazy voxel access.
- class itk_dreg.base.image_block_interface.BlockPairRegistrationResult(status: itk_dreg.base.image_block_interface.BlockRegStatus, transform: Optional[itk_dreg.base.itk_typing.TransformType] = None, transform_domain: Optional[itk_dreg.base.itk_typing.ImageType] = None, inv_transform: Optional[itk_dreg.base.itk_typing.TransformType] = None, inv_transform_domain: Optional[itk_dreg.base.itk_typing.ImageType] = None)¶
Encapsulate result of fixed-to-moving registration over one block pair.
Initialization
- Parameters:
status – Status code indicating registration success or failure.
transform – The forward transform registration result, if any. The forward transform maps from fixed to moving space. The forward transform is the result of a single registration stage and may be added to a previous initial transform to map from fixed to moving space.
transform_domain – Oriented representation of the domain over which the forward transform is valid.
transform_domain
has no voxel data and serves as a metadata representation of an oriented bounding box in physical space.transform_domain
must be available if and only iftransform
is available.inv_transform – The inverse transform registration result, if any. The inverse transform maps from moving to fixed space. If
inv_transform
is available thentransform
must also be available.inv_transform_domain – Oriented representation of the domain over which the inverse transform is valid.
inv_transform_domain
has no voxel data and serves as a metadata representation of an oriented bounding box in physical space.inv_transform_domain
must be available if and only ifinv_transform
is available.
- class itk_dreg.base.image_block_interface.LocatedBlockResult¶
Encapsules pairwise registration result information with contextual information describing how the fixed subimage in registration relates to the greater fixed image.
- result: itk_dreg.base.image_block_interface.BlockPairRegistrationResult¶
None
The result of pairwise subimage registration. May include extended information for specific implementations.
- fixed_info: itk_dreg.base.image_block_interface.BlockInfo¶
None
Oriented representation of the fixed image block over which pairwise registration was performed to produce the encapsulated registration result information.
- class itk_dreg.base.image_block_interface.RegistrationTransformResult¶
Encapsulate result of fixed-to-moving registration over all block pairs.
- transform: itk_dreg.base.itk_typing.TransformType¶
None
The forward transform resulting from block postprocessing. The forward transform maps from moving to fixed space.
- class itk_dreg.base.image_block_interface.RegistrationResult¶
Encapsulate result of fixed-to-moving registration over all block pairs.
- transforms: itk_dreg.base.image_block_interface.RegistrationTransformResult¶
None
The forward and inverse transforms resulting from registration.
- status: numpy.typing.ArrayLike¶
None
status
is an ND array where each element reflects the status code output for block pair registration over the corresponding input fixed chunk.status
has the same shape as the fixed input array of chunks. That is, if the fixed input array is subdivided into 2 chunks x 3 chunks x 4 chunks,status
will be an array of voxels with shape [2,3,4].