Hi,
I’m unable to identify what file is making the conversion process from DICOM to Nii to crash, is there a way to print this information so I can address the corrupted DICOM file?.
The outcome error is
INFO | Running: dcm2niix -b y -ba y -z y -f %3s_%f_%p_%t -o /Users/andrea/BIDS_TEST2/tmp_dcm2bids/helper sourcedata/CHRM2016
I will let @neurolabusc, @Chris_Rorden to answer you since it seems to be a dcm2niix issue.
Once fixed, if you have any issue with dcm2bids don’t hesitate.
@Andrea_18 The error you are reporting is coming from a wrapper, not dcm2niix, so I am not sure how much advice I can provide.
To trouble shoot this, you can attempt to use dcm2niix in isolation. I would suggest running dcm2niix directly from the command line, rather than a wrapper.
Make sure you are running the latest version of dcm2niix. So running dcm2niix without any arguments should report v1.0.20240202.
Convert your images with dcm2niix directly from the command line and inspect the errors and warnings it reports. Assuming you have write permission to the folder with your images, this would look like dcm2niix /path/to/DICOMs.
DICOM images tend to have a huge number of files without helpful filenames. To isolate your problem, you may want to rename your DICOMs so that they are organized in separate folders by series. To do this, you can use the r y argument, so dcm2niix -r y /path/to/DICOMs. You can then attempt to convert each of the series separately to get better insight into your problem.
My fault, our soon new dcm2bids version will highlight potentials errors coming from the dcm2niix conversion. For now, follow @neurolabusc instructions then dcm2bids should run smoothly.