I am using version 4.11.0-2020-08-09
I have converted some segmentation from numpy format to nrrd, I also converted my CT volume from numpy to nrrd, I am able to load them fine in slicer 3d, but I wanted to convert this to dicom format so that the segmentations as well as the CT can be read by dicom viewers.
The RT structure set does not even show up in the series list in the screenshot. What viewer are you trying to use?
I would recommend to use DICOM Segmentation Object (instead of the archaic and very limited RT structure set). This option shows up after you install Quantitative reporting extension. For future reference, see list of supported DICOM information objects here.
I was using RadiAnt DICOM Viewer to view the folder containing the exported dicom files and the RTstruct but for some reason the RTStruct doesnt show up.
When I try to export to DICOM Segmentation Object using the Quantitative reporting extension I get two errors. I had loaded the segmentation nrrd as label map and the primary CT volume is also an nrrd object.
Error 1 -
Could not retrieve DICOM tag value from input parameter None
Error 2 -
Traceback (most recent call last):
File “”, line 2, in
File “C:/Users/gabri/AppData/Roaming/NA-MIC/Extensions-29335/QuantitativeReporting/lib/Slicer-4.11/qt-scripted-modules/DICOMSegmentationPlugin.py”, line 350, in export
exporter.export(exportable.directory, segFileName, metadata)
File “C:/Users/gabri/AppData/Roaming/NA-MIC/Extensions-29335/QuantitativeReporting/lib/Slicer-4.11/qt-scripted-modules/DICOMSegmentationPlugin.py”, line 499, in export
absolutePaths=True)
File “C:/Users/gabri/AppData/Roaming/NA-MIC/Extensions-29335/QuantitativeReporting/lib/Slicer-4.11/qt-scripted-modules/DICOMSegmentationPlugin.py”, line 575, in getDICOMFileList
instanceUIDs = volumeNode.GetAttribute(attributeName)
AttributeError: ‘NoneType’ object has no attribute ‘GetAttribute’
You need to set the referenced image before you can export a DICOM Segmentation Object. To do this, you can go to Segment Editor module and choose the referenced image as Master volume. We’ll update the exporter to make this requirement more clear.
Sorry to bring back this old issue, but was there any success here? Was trying to do something similar (export seg from NRRD to DICOM) without success.
DICOM Segmentation Object export works well, it just complicated because of required cross-references between DICOM files.
If you use a recent Slicer Preview Release then you will get detailed error message about what steps were missed.
If you don’t export to existing DICOM studies but you make up new ones then you need to create the patients, studies, image series first and then associate this DICOM volume with the existing segmentation:
Export the volume to the DICOM database and then load the volume from the DICOM database.
Drag-and-drop the segmentation under the loaded DICOM volume’s study.
Go to Segment Editor and set the loaded DICOM volume as source geometry (by clicking the Specify geometry button and selecting the loaded DICOM volume as “source geometry”)