# Access to List of Segmented Organs

**URL:** <https://discourse.slicer.org/t/access-to-list-of-segmented-organs/40080>\
**Category:** Support\
**Created:** [November 8, 2024, 11:57am UTC](https://discourse.slicer.org/t/access-to-list-of-segmented-organs/40080 "2024-11-08T11:57:05Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Filippo\_Parronchi](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/filippo_parronchi/32/77852_2.png) [@Filippo\_Parronchi](https://discourse.slicer.org/u/Filippo_Parronchi)\
**Post date:** [November 8, 2024, 11:57am UTC](https://discourse.slicer.org/t/access-to-list-of-segmented-organs/40080/1 "2024-11-08T11:57:05Z")

</div>

Hello everyone.  
After applying the “totalSegmentator” module to my volume, I obtain a list of all segmented structures with their respective names, as shown in the figure. I would like to know how, through a Python script, I can access this list of structures by the name of the organ I am interested in (for example, “liver”), in order to get its corresponding index. This will be useful for then entering it as the “Label Value” in the “Mask Scalar Volume” module, allowing me to treat that object as an independent volume.  
Thanks a lot!!

 ![screen](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/5/7/576e147618ee81fd5915d531ca6d5b7701cc15b9.png)

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [November 10, 2024, 4:38am UTC](https://discourse.slicer.org/t/access-to-list-of-segmented-organs/40080/2 "2024-11-10T04:38:43Z")

</div>

What would you like to achieve? Create a fake CT from a segmentation so that you can import the segmentation into some clinical software?

---

<div class="post-metadata">

**Author:** ![Filippo\_Parronchi](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/filippo_parronchi/32/77852_2.png) [@Filippo\_Parronchi](https://discourse.slicer.org/u/Filippo_Parronchi)\
**Post date:** [November 10, 2024, 10:26pm UTC](https://discourse.slicer.org/t/access-to-list-of-segmented-organs/40080/3 "2024-11-10T22:26:47Z")

</div>

I needed access to the list so I could use the index related to the name of the organ of interest to set it as an input parameter for the “Mask Scalar Volume” module, specifically as the value of the Label Map to use in creating a new node. However, I might be able to work around this and solve it differently.

The aspect I need the most at the moment is the one discussed in this other topic:

> [@How to set parameters in "MaskScalarVolume" module via console](https://discourse.slicer.org/t/how-to-set-parameters-in-maskscalarvolume-module-via-console/40082):
>
> Hello, I am trying to run the “MaskScalarVolume” CLI module via Python console. With the lines of code shown in the figure, I am able to open the module interface and execute it (apply). I would like to know how to modify the input parameters indicated by the red arrow through the Python console. Thank you

I would be very grateful for any help with this!  
Thanks a lot!

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [November 11, 2024, 1:40am UTC](https://discourse.slicer.org/t/access-to-list-of-segmented-organs/40080/4 "2024-11-11T01:40:54Z")

</div>

Mask scalar volume is no longer relevant. Masking is now available in Segment Editor module (`Mask volume` effect).
