-
Hi folks, I'm trying to get scribbles working with the Slicer plugin and dev MONAILabel but having some trouble -- calling the scribbles update after adding some foreground scribbles doesn't update the organ label as expected. I'm running all the sample stuff
and a recent preview build of Slicer: 2022-03-28. My installed MONAILabel plugin is via adding the module path to the pulled down repo at f9e37fe. From there in Slicer I
and no changes are made to the spleen segment. If I select "spleen" instead of "background" in SmartEdit / Deepgrow > Label and then press update in scribbles, then the segment does stuff added to it, but it just ends up segmenting the entire space of the image. In the server logs I see that the background/foreground scribbles are expected to be labels 2/3
which tracks with the infer call here MONAILabel/monailabel/scribbles/infer.py Lines 103 to 104 in f9e37fe however, checking the created scribbles labelmap, the foreground scribbles have been assigned as 4. It seems that the labelmap export call assigns "background" - 1, "spleen" - 2, "background_scribbles" - 3, "foreground_scribbles" - 4 based on the generated segments in the label segmentation. MONAILabel/plugins/slicer/MONAILabel/MONAILabel.py Lines 1522 to 1524 in f9e37fe Am I missing something here? Is background not supposed to be added as a separate segment? |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 6 replies
-
@masadcv can you help here.. |
Beta Was this translation helpful? Give feedback.
-
I think I see the issue here, which is the use of I can provide a fix for this if this isn't the expected behavior. |
Beta Was this translation helpful? Give feedback.
-
Hello @adamaji, Many thanks for reporting this. It is not expected behavior. |
Beta Was this translation helpful? Give feedback.
Hello @adamaji, Many thanks for reporting this. It is not expected behavior.
I am debugging this, will update once I reproduce and step through the code.