open-discussion > Converting a directory of slices in dcm2niix
Showing 1-1 of 1 posts
Apr 30, 2021 10:04 AM | Walt Mankowski - University of Pennsylvania Perelman School of Medicine
Converting a directory of slices in dcm2niix
I've got a directory of numbered DICOMs where each file is a single
slice in a reconstructed breast tomosynthesis image. The files are
numbered
etc. If these are all in a directory named "slice_dir", then using dcm2nii I can run
$ dcm2nii slice_dir
and it combines them all into a single .nii.gz file. I can't figure out how to do the same thing using dcm2niix. I've tried a number of different combinations of parameters, but in each case what it does is convert each separate dcm into its own nifti file. Instead of, say, a single nifti file with 60 slices, I get 60 nifti files, each with a single slice.
Is this operation still supported in dcm2niix? If so, how do I do it?
Thanks.
Walt
- image.0.dcm
- image.1.dcm
- image.2.dcm
etc. If these are all in a directory named "slice_dir", then using dcm2nii I can run
$ dcm2nii slice_dir
and it combines them all into a single .nii.gz file. I can't figure out how to do the same thing using dcm2niix. I've tried a number of different combinations of parameters, but in each case what it does is convert each separate dcm into its own nifti file. Instead of, say, a single nifti file with 60 slices, I get 60 nifti files, each with a single slice.
Is this operation still supported in dcm2niix? If so, how do I do it?
Thanks.
Walt