tomaroberts / nii2dcm

nii2dcm: NIfTI to DICOM creation with Python
Other
53 stars 13 forks source link

Orientation of DICOM fies #28

Closed EnriqueFV closed 5 months ago

EnriqueFV commented 9 months ago

I, i have to process a directory of nifti files for a conectome analisis and i succesfully converted the files into dicom, as the software only works on a directory of dicom files. Now the software doesnt process the input folder as the images are in ALS orientation. This can be fix on -dicom type modality or is an aditional step to implement?. ITK-SNAP recognize the imagen as dicom series but does not tell much about orientation.

tomaroberts commented 9 months ago

Hi @EnriqueFV, thanks for raising an issue.

Currently, the orientation of the DICOMs is hard-coded – see here. I haven't implemented a more general solution to this yet. If you are familiar enough with Python, you could edit that line in nii2dcm or create a new --dicom-type (see svr.py for an example) where you override the default ImageOrientationPatient value.

One other thing which may or may not be useful: within ITK-Snap, you can play with orientation by going to: Tools > Reorient Image ...

This brings up the following menu where you can set and swap between orientations: image

However, to my knowledge, you can't use this to save a new DICOM dataset with an altered orientation.