open-discussion > Multiple DICOM to NIfTI converter using dcm2niiX (Win10)
Showing 1-3 of 3 posts
Display:
Results per page:
Dec 22, 2017  09:12 AM | Larry Lai
Multiple DICOM to NIfTI converter using dcm2niiX (Win10)
Dear Experts

I would like to convert multiple T1/Fun Raw DICOM using dcm2niiX.

How to write a script?

Thanks for considering my request.

Cheers
Larry
Dec 22, 2017  12:12 PM | Chris Rorden
RE: Multiple DICOM to NIfTI converter using dcm2niiX (Win10)
Larry-
 Assuming you ran a study with multiple individuals who each had a T1, DTI and fMRI scan, and all their DICOM files were in a single folder, you could convert these from the command line (or MRIcroGL's graphical interface) using a command like
  dcm2niix -f %t_%p_%s ~/dicomDir
This will generate NIfTI images where the filename includes study time (%t), protocol name (%p) and series number (%s). So an output mike look like 
  201712120100_T1_2
where the time tells provides the protocol tells you the modality, and the series number helps you distinguish multiple fMRI runs. If this solution is acceptable, you do not need a script at all. Likewise, you can wrap this command in your favorite scripting language (Python, Matlab, shell, etc).

Another option might be to convert your DICOM data to NIfTI data in a BIDS structure. There are a number of scripts that will allow you to do this. For example, see the "Links" section of the dcm2niix github page
  https://github.com/rordenlab/dcm2niix
Aug 27, 2018  11:08 AM | Larry Lai
RE: Multiple DICOM to NIfTI converter using dcm2niiX (Win10)
Dear Chris

Thanks for the information.

Best regards
Larry