Dialog and controller for configuring and running data pre-processing steps.
PreProcessing coordinates a set of optional, independently toggleable operations that are applied to the data currently loaded in the DataManager, in the following order:
- Bed removal (classic or advanced, via CTBedRemoval / AdvancedBedRemovalDialog)
- Co-registration of secondary datasets to the first loaded dataset (RegistrationTools)
- Auto-cropping (via the active SliceViewer's CroppingOperator)
- Per-modality calibration factor application
- Isotropic resampling to a target voxel size (ReorientationOperator)
- Unit conversion (e.g. counts, concentration, ID, ID/g, SUV), which may require injected dose and/or patient weight to be supplied or derived from DICOM headers
- Series description comment tagging
- Quality Control snapshot image generation and storage to a DICOM repository
Settings for each step are persisted to and restored from QSettings under the "Analysis" group (storeSettings() / loadSettings()), and can also be serialized to/from a compact pipe-delimited "protocol" string (settingsToString() / stringToSettings()) so that a full configuration can be captured, shared, or replayed via setProtocol().
Dose and weight values used for unit conversion can be sourced automatically from the loaded image's DICOM header (including decay-corrected dose and lean-body-mass-corrected weight), overridden manually, or restored from previously stored settings; see updateInjectedDose(), updateWeight(), and the associated setters/getters.
The class can be driven interactively as a modal dialog (show() / showDialog()) or invoked non-interactively from VQScript by supplying a protocol string directly to execute(), which runs the entire enabled pipeline and returns a status message.
See also VQ.PreProcessingTool() to obtain this object.
|
|
void | storeSettings () |
| | Save current Preprocessing settings into the VQ settings.
|
|
void | loadSettings () |
| | Load current VQ settings for Preprocessing.
|
| string | settingsToString () |
| | Dump current Preprocessing settings to a string.
|
| void | stringToSettings (string params) |
| | Apply Preprocessing settings (| - delimited and defined with key=value) to the Preprocessing settings.
|
| void | setProtocol (string protocol) |
| | Set values in the PreProcessing Tool based on the provided protocol string.
|
| string | execute (string protocol=string()) |
| | Set values in the PreProcessing Tool based on the provided protocol string and execute the pre-processing based on these settings.
|
| void | setComment (string comment) |
| | Add a comment to the series description of all loaded data. Each image should be marked as updated and will get a DICOM derivation entry on save.
|
| void | setConvertUnit (string convertUnit) |
| | Set the target unit for image unit conversions, for example Ci, MBq, SUV, etc. Accepts either the current canonical spelling (e.g. "g/ml") or a recognized legacy alias (e.g. "SUV"); the corresponding unit-type category (Counts, Concentration, Percent, Per Weight/Mass, or SUV) is derived automatically – callers do not need to know about or set the unit-type category separately.
|
| string | getConvertUnit () |
| | Get the current unit images will be converted to.
|
| string | getConvertUnitType () |
| | Get the current unit-type category (Counts, Concentration, Percent, Per Weight/Mass, or SUV) associated with getConvertUnit(). This reflects the category cbUnitType is currently set to; it is derived automatically by setConvertUnit() and does not need to be set independently.
|
| string | convertUnit (string &outUnit) |
| | Convert an image's units to another's.
|
| string | createQCImages (AbstractDicomRepository *rep) |
| | Generate Quality Control images with the preprocessing tool.
|
| void | setUptakeParameter (string source, string parameter, Array< string > info, Index idx=Index()) |
| | Change the value of a parameter used for decay correction.
|
| void | setPreferredUptakeSource (string source, Index idx=Index()) |
| | Change the preferred source to check for decay correction parameters.
|
| void | setUptakeSourceOrder (Array< string > sourceList, Index idx=Index()) |
| | Change the order in which to check sources for decay correction parameters.
|
| void | setInjectedDoseValue (string doseValue) |
| | Set the injected dose value.
|
| void | setInjectedDoseUnit (string doseUnit) |
| | Set the injected dose unit.
|
| string | getImgInjectedDoseValue (Index idx=Index()) |
| | Get the injected dose for a given image's DICOM header.
|
| string | getImgInjectedDoseUnit (Index idx=Index()) |
| | Get the injected dose for a given image's DICOM header.
|
|
string | getInjectedDoseValue () |
| | Get the current injected dose value setting in the preprocessor.
|
|
string | getInjectedDoseUnit () |
| | Get the current injected dose unit setting in the preprocessor.
|
| void | setWeightValue (string weightValue) |
| | Set the value of the weight value setting in the preprocessor.
|
| void | setWeightUnit (string weightUnit) |
| | Set the unit of the weight unit setting in the preprocessor.
|
| string | getImgWeightValue (Index idx=Index()) |
| | Get the weight value of a loaded image.
|
| string | getImgWeightUnit (Index idx=Index()) |
| | Get the weight unit of a loaded image.
|
|
string | getWeightValue () |
| | Get the current weight value.
|
|
string | getWeightUnit () |
| | Get the current weight unit.
|
|
void | updateUptakeParameters () |
| | Update uptake information. Should be called after calls to setUptakeParameter().
|
| void | setStoreRepository (AbstractDicomRepository *rep) |
| | Sets the DICOM repository for storage of QC images.
|
| bool | isValidQCFilename (string filename) |
| | Checks whether or not the provided filename can be used for saving Quality Control image files.
|
| string | parseQCFilename (string filename) |
| | Scans a filename format string and replaces special characters with header key names.
|
| string | parseQCFilename (ImageData *image, string filename) |
| | Scans a filename format string and replaces special characters with header values from an image.
|