Update existing volume from SimpleITK image

Thank you simonoxen. It worked for me.
I need guidance with one other issue. I use the method sitkUtils.PushVolumeToSlicer each time I want to display a volume node on screen. I have a button and whenever this button is clicked, some operation is performed internally and the resulting volume is pushed to screen with the name ‘XYZ’. In general, I keep varying the parameters and clicking the button multiple times in order to get the right output. But, this creates multiple nodes all named ‘XYZ’.

Is there any way to overwrite or delete the previous node named ‘XYZ’ before creating the new one. That way I won’t get confused with the names of the nodes while saving.

You can specify to which node the volume is pushed. If you specify an existing node you can overwrite it. See script repository: simple itk

1 Like