PyMAIA_convert_NIFTI_predictions_to_DICOM_SEG script#
Script to convert NIFTI Predictions ( as output from the model inference ), back into the original DICOM context ( as SEG modalities ). The NIFTI Predictions are converted into DICOM SEG and assigned to the corresponding original DICOM Study.
usage: PyMAIA_convert_NIFTI_predictions_to_DICOM_SEG [-h] --data-folder
DATA_FOLDER
--dicom-folder
DICOM_FOLDER
--output-folder
OUTPUT_FOLDER
--pred-suffix PRED_SUFFIX
[--n-workers N_WORKERS]
--template-file
TEMPLATE_FILE
--study-id-summary
STUDY_ID_SUMMARY
[-v | -q]
Named Arguments#
- --data-folder
Data Folder containing the NIFTI Predictions.
- --dicom-folder
DICOM Folder containing the original Data.
- --output-folder
Folder where to store the generated DICOM SEG.
- --pred-suffix
Suffix to append to the Patient folder name to identify the NIFTI prediction.
- --n-workers
Number of Parallel Threads.
Default:
'1'- --template-file
DCMQI DICOM SEG Template, generated from http://qiicr.org/dcmqi/#/seg
- --study-id-summary
Study ID Summary, generated when converting the DICOM Dataset to a NIFTI Dataset.
- -v, --verbose
Enable verbose output in terminal. Add multiple times to increase verbosity.
- -q, --silent
Suppress most log outputs in terminal.
Example call:
PyMAIA_convert_NIFTI_predictions_to_DICOM_SEG --data-folder <NIFTI_DATA_FOLDER> --dicom-folder <DICOM_DATA_FOLDER> --output-folder <DICOM_SEG_FOLDER> --pred-suffix _seg.nii.gz --template-file <DCMQI_TEMPLATE> --study-id-summary STUDY_ID_DICT.json