Extract selected segments

(the topic was originally posted by @Samaneh - but it was accidentally rejected while reviewing the moderation queue)

Hi everyone,
I have got a series of mammography and ultrasound images that I segmented by 3d slicer. I want to extract selected segments using the codes below:


However, I do not have any “SegmentationExtracted.seg.nrrd” file to load in python.
Can anyone guide me how to use these codes?

Hi,
I sent you a question about how to extract selected segments by the codes that I have sent to you, however it was accidentally rejected while reviewing the moderation queue.I would be greatly thankful if you answer my question.

This is a placeholder for the file system path to the file where you saved your segmentation.