voxtox.core module
Core functions specific to analysis of VoxTox data
- voxtox.core.get_couch_rotations(ds=None, group=153, element=4114, reverse=False)
Retreive couch rotations stored as DICOM private data.
Couch rotations are stored and retrieved as:
pitch (about x-axis), yaw (about y-axis), roll (about z-axis)
These represent the second part of the transformation (translations + rotations) for mapping from the guidance scan to the planning scan. In practice, pitch and yaw are always zero.
Parameters:
- dspydicom.dataset.FileDataset/None, default=None
Dataset containing couch shifts stored as private data.
- groupint, default=couch_shits_group
Location of the private group where couch shifts are stored.
- element: int, default=rotations_element
Location of the private element, within the private group, where couch rotations are stored (default corresponds to VoxTox).
- reversebool, default=False
If True, signs of couch rotations are reversed.
- voxtox.core.get_couch_shifts(image=None, reverse=False)
Retreive couch shifts for a given CT guidance scan.
In VoxTox, couch shifts for an MV CT guidance scan define the adjustments applied by a radiographer after examining the scan, to match the position at planning time as closely as possible.
Couch shifts are retrieved as:
translations: dx, dy, dz
rotations: pitch (about x-axis), yaw (about y-axis), roll (about z-axis)
These represent the transformation for mapping from the guidance scan to the planning scan. In practice, pitch and yaw are always zero.
Parameters:
- imageskrt.image.Image/None, default=None
Image object for which couch shifts are to be retrieved.
- reversebool, default=False
If True, signs of couch shifts are reversed.
- voxtox.core.get_couch_translations(ds=None, group=153, element=4113, reverse=False)
Retreive couch translations stored as DICOM private data.
For historical reasons, couch translations are stored as:
+dx, -dz, +dy
They are rearranged here as:
+dx, +dy, +dz
These represent the first part of the transformation (translations + rotations) for mapping from the guidance scan to the planning scan.
Parameters:
- dspydicom.dataset.FileDataset/None, default=None
Dataset containing couch shifts stored as private data.
- groupint, default=couch_shifts_group
Location of the private group where couch shifts are stored.
- element: int, default=translations_element
Location of the private element, within the private group, where couch translations are stored (default corresponds to VoxTox).
- reversebool, default=False
If True, signs of couch translations are reversed.
- voxtox.core.unpack_couch_shifts(ds=None, group=None, element=None, n_shift=3, reverse=False)
Unpack couch shifts stored as DICOM private data.
Parameters:
- dspydicom.dataset.FileDataset/None, default=None
Dataset containing couch shifts stored as private data.
- groupint/None, default=None
Location of the private group where couch shifts are stored.
- element: int/None, default=None
Location of the private element, within the private group, where couch shifts are stored.
- n_shift: int, default = 3
Number of shifts stored in an element (default corresponds to VoxTox).
- reversebool, default=False
If True, signs of couch shifts are reversed.