Closed bpinsard closed 11 years ago
@bpinsard, you might want to take a look at our fork of dcmstack at https://github.com/IBIC/dcmstack that has some support for Philips Enhanced DICOM. Hoping to get these changes incorporated into the main branch of dcmstack soon.
I haven't seen this before. Could you send me the JSON? For example you could do "nitool dump myfile.nii.gz > myjson.txt".
I had tried the guess-dim branch directly on the enhanced data but the same thing happens. here are the lines I extracted that make json library crash at loading:
"DimensionIndexSequence": [
{
"DimensionOrganizationUID": "2.16.124.113543.6006.99.02479373120167955565",
"DimensionIndexPointer": (0020, 9056),
"FunctionalGroupPointer": (0020, 9111)
},
{
"DimensionOrganizationUID": "2.16.124.113543.6006.99.02479373120167955565",
"DimensionIndexPointer": (0020, 9057),
"FunctionalGroupPointer": (0020, 9111)
}
],
maybe these self referential dicom tags code are the problem?
It looks like those tags are not being serialized correctly. What is the VR of those elements?
the VR is AT
Could you test the referenced branch, I think it should fix the issue. You will need to reconvert the files.
it works, thanks, maybe these tags should be filtered out as they do refers to dicoms ?
OK, merged it into master.
Currently, the default filtering is just intended to remove PHI. It should however be easy enough to filter any tag with a given VR if a user wants that.
I ran into an issue with specific MPRAGE dicoms unenhanced from Philips 3D to 2D dicoms. Using dcmstack, I am able to parse, create niftiwrapper and save it, but when trying to load it using
nibabel.load
ordcmstack.NiftiWrapper.from_filename
it raise a JSON error:The nifti file is otherwise loaded when dcmstack is not in the library path. It is also opened in any other software. Any idea about what could cause this? Thanks.