Display issue with RT structs and MR volume

Operating system: Ubuntu 16.04 LTS (tried on Windows 10 with the same result)
Slicer version: 4.7.0-2017-06-03 r26072
Expected behavior: RT struct with contouring done in the axial view in a radiotherapy planning software. If this contour is viewed in Slicer in the axial view, there should be a contour for each slice and the contour should be aligned with the image volume
Actual behavior: Contour is ‘tilted’ (see screenshot)

Dear all,

We have postoperative MR of GBM patients, with the contour of the cavity as an RT struct. The contouring was done in the radiotherapy planning software on axial slices. When loaded into Slicer, the contours are not aligned with the axial slices:

I am not sure if that’s a problem on our side or if for some reason Slicer does not display it correctly. Due to this tilt, we have issues creating label maps from the contours. Additionally, the contouring “slices” of the RT struct are not equally spaced when viewed in the 3D window.
I cannot publicly share the anonymized data here, if someone can help and try to reproduce it, I can send it e.g. by email.

Any help highly appreciated.

Best and thank you,

Yannick

Hello Yannick,

It looks like there is a problem with the planar contour to closed surface conversion.
If you could send me an email with the data, I will see if I can figure out what the problem is.
I will message you with my email.

Thanks!
Kyle

1 Like

It seems that your MR volume axes are not aligned with patient anatomical axes. It’s not a problem, Slicer just shows slice viewers aligned with anatomical axes by default. Click “Rotate to volume plane” button in the slice view controller to align slice viewers to volume planes:

In the treatment planning software, did you draw contours with variable distance between them?

1 Like

Hi Andras and Kyle,

Thanks, that helped a lot already! Rotating to volume plane gets rid of the “tilt”. The contour “slices” are now aligned with the volume in the 3D view. If I change the Segmentations display to “planar contour”, the contour “slices” seem equally spaced - great! Yes, the contours were done on all (equally spaced) axial slices.

What’s still strange is the label map generated from the contours:

Is it possible that the rotation of the volume plane is not considered when the label maps are created?

Best and thanks,

Yannick

The default labelmap conversion goes through the pathway: planar contours -> closed surface -> binary labelmap, so if there is an issue with the surface, that issue will be propagated to the labelmap.

For now, you can work around this issue by using the planar contour -> ribbon model -> binary labelmap conversion instead.

You can do this in the Segmentations module by long-pressing the create button and selecting advanced create (or clicking the update button if the labelmap has already been created) beside the binary labelmap representation, and selecting a different conversion path.

Let me know if this helps!

Thanks,
Kyle

1 Like

Kyle’s suggested fix should work - I’ve used it for other data.

I’ll just not @yannick_s that with MR often an “axial” image will still be rotated with respect to patient space, for example so that the rectangular bounds of the scanned region best capture the target anatomy efficiently. That could be why the is like this.

1 Like

Ok, I tried both paths to create the binary label map. The closed surface and planar contour are both available when loading the segmentation, with the planar contour as master. It looks like there are multiple polygons per axial slice (sometimes overlapping), which seems to confuse the label map creation. Here’s a screenshot of a relatively “benign” example:

Left: Segmentation as a closed surface, Right, purple label: label map created with planar contour → ribbon model → binary labelmap; right, green label: planar contour → closed surface → binary labelmap

Maybe I have to combine all polygons per slice first to get anything meaningful out of this.

@pieper Is there a way to check if the “axial” image is rotated with respect to the patient space?

Thanks for the help!

@yannick_s yes, look in the Volumes -> Information -> IJKToRAS non-identity (+/-) terms.

https://www.slicer.org/wiki/Documentation/4.6/Modules/Volumes

Also note that RT structures will often (usually?) overlap because both tumor and treatment volumes are includes. These don’t map to a single labelmap. I’m not sure if that’s what’s happening in your case.

1 Like

Thanks!
I checked, only the postop cavity should be in the segmentation. But apparently, the segmentation was not done with a single contour per slice, but sometimes with several polygons per slice to capture the whole cavity.

For me it looks like the binary label map conversion get’s confused by multiple polygons:

@pieper
I have a IJLToRAS transform looking like this.
IJKtoRAS =
[-0.9982, -0.0550, 0.0218
0.0495 -0.9777 -0.2042
0.0325 -0.2028 0.9787]
So, to align the axial image to patient space, I have to transform the volume so that it gets [-1,0,0;0,-1,0,10,0]? to avoid flipping?

Having multiple contours in the same slice in the same structure does not seem to be valid. DICOM standard Part 3 C. 8.8.6 does not explicitly say that intersection is prohibited, but “closed contour (polygon) containing coplanar points” indicates that a simple polygon is expected. It is explicitly stated that you cannot even make a hole in a polygon (you need to use keyhole technique instead).

Did you draw multiple contours in the same slice in the same structure in the treatment planning system? Or you have distinct contours in the treatment planning system but they show up at the same slice in Slicer?

1 Like

Hi everyone,

Thank you all for the great help. It looks like the artifacts came from exporting from the clinical system where some “re-slicing” occurred.

Hi All,

I have the same problem… After importing the RT-Structure Dicom set from TPS to 3Dslicer, I start having gabs or blanks between slides exactly as showing by yannick_sYannick image above. I tried to follow lassoan suggestions, it did work in the Sagital plan not the axial nor coronal view.

Any suggestions, please?

Thanks in advance for your help!
Rasga

I still have gabs between the slides. Can you please explain again how can I have no gabs between the slides? Please

Please provide a screenshot of the structure set in the TPS and in 3D Slicer.

Hi,

Did you try rotating to volume plane for each view? There’s a button for this in all three (coronal, axial, sagittal) views, @lassoan pointed me to in a post above.

Yes, I was able to rotate to volume plan only for sagital view. Doing the same way to other views do not work (axial and coronal views).

Here is the screenshot of TPS

Here is in 3D slicer. The file it too big to upload it at once.

Thank you. Could you share an anonymized data set using Dropbox or OneDrive so that we can investigate and fix the problem?

I am afraid that I can not share the data in public. However, would the structure set be okay to diagnose the problem?