open-discussion > How to convert .raw file format to nifty/nii..
Showing 1-3 of 3 posts
Jan 31, 2020 11:01 AM | Najam Ur rahman - GIK Institute
How to convert .raw file format to nifty/nii..
How to convert .raw file format to nifty/nii..
Aug 2, 2020 12:08 PM | Ghazn Khan - University of Manchester
RE: How to convert .raw file format to nifty/nii..
Originally posted by Najam Ur rahman:
Has anyone been able to figure this out?
When downloading the dataset it is in .nhdr/.raw format. How would I convert this to .nii format?
How to convert .raw file format to
nifty/nii..
Hi, Has anyone been able to figure this out?
When downloading the dataset it is in .nhdr/.raw format. How would I convert this to .nii format?
Dec 17, 2020 07:12 PM | Roberto Mena
RE: How to convert .raw file format to nifty/nii..
You could use python and SimpleITK, to transform the file. Let`s
say you are in the folder `\CHB_train_Part1\CHB_train_Case01`
,
you would do:
>>> import SimpleITK as sitk
>>> img = sitk.ReadImage('CHB_train_Case01_FLAIR.nhdr')
>>> sitk.WriteImage(img, 'CHB_train_Case01_FLAIR.nii.gz')
you would do:
>>> import SimpleITK as sitk
>>> img = sitk.ReadImage('CHB_train_Case01_FLAIR.nhdr')
>>> sitk.WriteImage(img, 'CHB_train_Case01_FLAIR.nii.gz')