Usage¶
Dynamic PET provides two CLI functions: denoise
and kineticmodel
.
denoise
operates on 4-D images only.
Currently, only the HYPR-LR algorithm is available.
kineticmodel
is a flexible function that can operate on images or time activity curve (TAC) files.
PET Inputs¶
Images¶
PET image inputs to Dynamic PET functions should be 4-D images with the last dimension corresponding to time.
The only exception to this is standardized uptake value ratio (SUVR) calculation (kineticmodel --model SUVR
), which can operate on 3-D images (i.e., without a time dimension) as well as on 4-D images.
Time activity curves (TACs)¶
Time activity curves should be stored in a tab-separated values (tsv) file where
columns correspond to regions (or voxels) and rows correspond to time frames.
Column headers should indicate the region (or voxel) name.
There should not be any row headers.
Time frame information (i.e., frame start, frame duration) should not be included
in this file, as these will be extracted from the accompanying .json
file (see below).
Note
Example TAC file content
ROI1 |
MyFavBrainRegion |
---|---|
2.29 |
2.73 |
14.8 |
9.73 |
23.5 |
17.4 |
… |
Time framing information¶
Both PET image and TAC inputs should be accompanied by a .json
file that follows the PET-BIDS specification. The .json
file is not checked for compliance with the PET-BIDS specification, but should have the following fields for full functionality with Dynamic PET:
TracerRadionuclide: str
ScanStart: float
InjectionStart: float
FrameTimesStart: List[float]
FrameDuration: List[float]
Execution¶
denoise¶
Perform dynamic PET denoising.
Outputs will have a ‘_desc-<method>_pet’ suffix.
PET: 4-D PET image
denoise [OPTIONS] PET
Options
- --method <method>¶
Required Name of denoising method
- Options:
HYPRLR | NESMA
- --fwhm <fwhm>¶
Full width at half max in mm for smoothing (only for HYPR-LR)
- --mask <mask>¶
Binary mask specifying voxels where denoising should be performed. (only for NESMA)
- --window_half_size <window_half_size>¶
The size of search window centered around a voxel will be 2 * window_half_size + 1 (any part of the window that extends beyond the image will be truncated). (only for NESMA)
- --thresh <thresh>¶
threshold (only for NESMA)
- --outputdir <outputdir>¶
Directory in which to save denoised image. If not provided, it will be saved in the same directory as the PET image.
- --json <json>¶
PET-BIDS json file
Arguments
- PET¶
Required argument
kineticmodel¶
Fit a reference tissue model to a dynamic PET image or TACs.
Outputs will have a ‘_model-<model>_meas-<parameter>’ suffix.
PET: 4-D PET image (can be 3-D if model is SUVR) or a 2-D tabular TACs tsv file
kineticmodel [OPTIONS] PET
Options
- --model <model>¶
Required Name of kinetic model
- Options:
SUVR | SRTMLammertsma1996 | SRTMZhou2003
- --refroi <refroi>¶
Name of reference region. Required when PET is specified as a tsv file. REFROI option cannot be used if PET is specified as an image.
- --refmask <refmask>¶
3-D binary mask indicating reference tissue (must be in alignment with PET). REFMASK option cannot be used if PET is specified as a tsv file.
- --outputdir <outputdir>¶
Directory in which to save each estimated parametric image. If not provided, they will be saved in the same directory as the PET image.
- --json <json>¶
PET-BIDS json file. If not specified, it is assumed to have the same name as the PET image file, except with a .json extension.
- --petmask <petmask>¶
Binary mask specifying voxels where model should be fitted. Voxels outside this binary mask in the resulting parametric images will be set to NA.
- --start <start>¶
Start of time window for model in min
- --end <end>¶
End of time window for model in min
- --fwhm <fwhm>¶
Full width at half max in mm for smoothing, used for some models
- --weight_by <weight_by>¶
Frame weights used in estimation procedures involving regression.
- Options:
frame_duration
- --integration_type <integration_type>¶
Integration type used in estimation procedures involving time integrals. ‘trapz’ is trapezoidal integration and ‘rect’ is rectangular integration.
- Options:
rect | trapz
Arguments
- PET¶
Required argument