Orientation¶
voxel.Orientation(item)
¶
The anatomical orientation of the voxel coordinate system.
There are 48 possible orientations of voxel data in a 3D grid. These are defined by the permutations and flips of the grid axes relative to a global coordinate space. By default, we use a 'RAS' anatomical world coordinate system, which is characterized by the following axis directions:
- x axis: left (L) to right (R)
- y axis: posterior (P) to anterior (A)
- z axis: inferior (I) to superior (S)
Thus, orientations are defined by a three-character string, which maps a voxel coordinate axis to the corresponding anatomical axis direction in 'RAS' space.
Parameters:
-
item(str | AffineMatrix) –Orientation string or affine matrix.
name: str
property
¶
Abbreviated orientation name.
dim_map(target) -> torch.Tensor
¶
Map dimensions from this orientation to another.
Parameters:
-
target(Orientation) –Target orientation.
Returns:
-
Tensor–3D integer mapping of dimensions.
view(dim) -> str
¶
Get the name of the view plane (axial, coronal, sagittal) for a given dimension.
Parameters:
-
dim(int) –Dimension index.
Returns:
-
str–View plane name.