icometrix/dicom2nifti

How to rename the output file (e.g. 202_.nii.gz)

angolin22 opened this issue · 1 comments

Hello,
thanks for your work, I want to ask that how to rename the output file (e.g. 202_.nii.gz)

Could you please provide a little more information no how you are using dicom2nifti.
If it is being used from a script or the command line utility?

When used from the command line or from a script using the convert_directory function the naming is automatic as there can be multiple series within one directory.
Naming is than handles as followed
SeriesNumber_SeriesDescription.nii.gz, SeriesNumber_SequenceName.nii.gz, SeriesNumber_ProtocolName.nii.gz or SeriesNumber.nii.gz

The generated name points to a series with series number 202 and SeriesDescription, SequenceName or ProtocolName present but empty.

Choosing a name during conversion would only be possible if you convert from a python script using dicom_series_to_nifti which allows for an output file to be specified