pytomography.io.PET.prd.types
#
Module Contents#
Classes#
All information about a coincidence event specified as identifiers or indices (i.e. discretized). |
|
Items describing the exam (incomplete) |
|
Detector ID and location. Units are in mm |
|
Time interval in milliseconds since start of acquisition |
|
A sequence of time intervals (could be consecutive) |
Functions#
Attributes#
- class pytomography.io.PET.prd.types.CoincidenceEvent(*, detector_1_id=0, detector_2_id=0, tof_idx=0, energy_1_idx=0, energy_2_idx=0)[source]#
All information about a coincidence event specified as identifiers or indices (i.e. discretized). TODO: this might take up too much space, so some/all of these could be combined in a single index if necessary.
- Parameters:
detector_1_id (pytomography.io.PET.prd.yardl_types.UInt32) –
detector_2_id (pytomography.io.PET.prd.yardl_types.UInt32) –
tof_idx (pytomography.io.PET.prd.yardl_types.UInt32) –
energy_1_idx (pytomography.io.PET.prd.yardl_types.UInt32) –
energy_2_idx (pytomography.io.PET.prd.yardl_types.UInt32) –
- class pytomography.io.PET.prd.types.Subject(*, name=None, id='')[source]#
- Parameters:
name (Optional[str]) –
id (str) –
- class pytomography.io.PET.prd.types.Institution(*, name='', address='')[source]#
- Parameters:
name (str) –
address (str) –
- class pytomography.io.PET.prd.types.ExamInformation(*, subject=None, institution=None, protocol=None, start_of_acquisition=None)[source]#
Items describing the exam (incomplete)
- Parameters:
subject (Optional[Subject]) –
institution (Optional[Institution]) –
protocol (Optional[str]) –
start_of_acquisition (Optional[pytomography.io.PET.prd.yardl_types.DateTime]) –
- institution: Institution[source]#
- start_of_acquisition: pytomography.io.PET.prd.yardl_types.DateTime | None[source]#
- class pytomography.io.PET.prd.types.Detector(*, id=0, x=0.0, y=0.0, z=0.0)[source]#
Detector ID and location. Units are in mm TODO: this is currently just a sample implementation with “point” detectors. We plan to have full shape information here.
- Parameters:
id (pytomography.io.PET.prd.yardl_types.UInt32) –
x (pytomography.io.PET.prd.yardl_types.Float32) –
y (pytomography.io.PET.prd.yardl_types.Float32) –
z (pytomography.io.PET.prd.yardl_types.Float32) –
- class pytomography.io.PET.prd.types.ScannerInformation(*, model_name=None, detectors=None, tof_bin_edges=None, tof_resolution=0.0, energy_bin_edges=None, energy_resolution_at_511=0.0, listmode_time_block_duration=0)[source]#
- Parameters:
model_name (Optional[str]) –
detectors (Optional[list[Detector]]) –
tof_bin_edges (Optional[numpy.typing.NDArray[numpy.float32]]) –
tof_resolution (pytomography.io.PET.prd.yardl_types.Float32) –
energy_bin_edges (Optional[numpy.typing.NDArray[numpy.float32]]) –
energy_resolution_at_511 (pytomography.io.PET.prd.yardl_types.Float32) –
listmode_time_block_duration (pytomography.io.PET.prd.yardl_types.UInt32) –
- tof_bin_edges: numpy.typing.NDArray[numpy.float32][source]#
edge information for TOF bins in mm (given as from first to last edge, so there is one more edge than the number of bins) TODO: this currently assumes equal size for each TOF bin, but some scanners “stretch” TOF bins depending on length of LOR
- energy_bin_edges: numpy.typing.NDArray[numpy.float32][source]#
edge information for energy windows in keV (given as from first to last edge, so there is one more edge than the number of bins)
- energy_resolution_at_511: pytomography.io.PET.prd.yardl_types.Float32[source]#
FWHM of photopeak for incoming gamma of 511 keV, expressed as a ratio w.r.t. 511
- class pytomography.io.PET.prd.types.Header(*, scanner=None, exam=None)[source]#
- Parameters:
scanner (Optional[ScannerInformation]) –
exam (Optional[ExamInformation]) –
- scanner: ScannerInformation[source]#
- exam: ExamInformation | None[source]#
- class pytomography.io.PET.prd.types.TimeBlock(*, id=0, prompt_events=None, delayed_events=None)[source]#
- Parameters:
id (pytomography.io.PET.prd.yardl_types.UInt32) –
prompt_events (Optional[list[CoincidenceEvent]]) –
delayed_events (Optional[list[CoincidenceEvent]]) –
- id: pytomography.io.PET.prd.yardl_types.UInt32[source]#
number of the block. Multiply with listmodeTimeBlockDuration to get time since startOfAcquisition
- prompt_events: list[CoincidenceEvent][source]#
list of prompts in this time block TODO might be better to use !array
- delayed_events: list[CoincidenceEvent] | None[source]#
list of delayed coincidences in this time block
- class pytomography.io.PET.prd.types.TimeInterval(*, start=0, stop=0)[source]#
Time interval in milliseconds since start of acquisition
- Parameters:
start (pytomography.io.PET.prd.yardl_types.UInt32) –
stop (pytomography.io.PET.prd.yardl_types.UInt32) –
- class pytomography.io.PET.prd.types.TimeFrameInformation(*, time_frames=None)[source]#
A sequence of time intervals (could be consecutive)
- Parameters:
time_frames (Optional[list[TimeInterval]]) –
- time_frames: list[TimeInterval][source]#