Step #2: Setting Up a MONAI Label Slicer Module

Once the environment and the server are up and running, we move to the viewer side. Inside this instance, located on the Desktop is the 3D Slicer software that you can use to interact with the MONAI Label module.

The Desktop can be found on the top left on this page:

radiology-012.png

Once inside the Desktop, open the Slicer folder:

radiology-013.png

And then the subfolder:

radiology-014.png

And double-click to the Slicer application:

radiology-015.png

Once Slicer is opened, go to View -> Extension Manager -> Install Extensions -> Active Learning.

radiology-003.png

You have to relaunch 3D Slicer after installing the MONAI Label module and then access it through the Modules -> Active Learning menu.

Once the module is installed, type this IP address and port (http://127.0.0.1:8000) into the MONAI Label Server field and click on the green circle icon as it is shown in the next image.

radiology-016.png

Once connected to the server, the next step is to fetch one of the unlabeled volumes. For this, click on Next Sample as shown in the image below:

radiology-017.png

Once fetched, you can see the three views of volume as shown here:

radiology-018.png

Now, you can use the default pretrained model to segment the spleen organ by using the auto segmentation functionality as follows:

radiology-019.png

Once segmented, you should get something like this:

radiology-020.png

You can show the 3D segmentation by clicking on the Show 3D button within the Segment Editor tab. The result will be something like this:

radiology-021.png

Use Center View if the segmentation isn’t completely visible

radiology-022.png

Once you get the prediction shown in 3D, you could update it by using the available tools in 3DSlicer (paint brush, scissor, eraser, etc) by first clicking on the segment name (Spleen) and then select the tool.

radiology-023.png

After modifying the label, or if the prediction is already good enough, you could submit it to the MONAI Label server for further model training or fine-tuning. For this, just click on Submit Label:

radiology-024.png
radiology-025.png

This action will save the annotation in the /home/nvidia/datasets/Task09_Spleen/unlabeled_imgs/labels/final/ folder located on the Desktop file system

radiology-026.png

When working with the local file archive as here, MONAI Label creates a folder called “labels” and two subfolders called “final” and “original”. In “final”, the system keeps the ground truth or expertly approved annotations, while in the “original” MONAI Label keeps the predictions from the model.

radiology-029.png

After submitting the label, the user could trigger the training and/or continue the annotation process by fetching the next sample. The annotator can trigger the training with the default values by clicking on Train as shown in the next image:

radiology-028.png

This process can be repeated until the expert sees the model performance is good enough.

Another common use of MONAI Label is when the user has many unlabeled volumes and a small percentage of annotated volumes. For this use case, we have created a folder called partially_labeled_imgs that simulates that situation and it is ready to be used by MONAI Label. This allows the user to train or fine-tune a model without the need to first correct predictions. They could trigger the training immediately after connecting to the server.

Feel free to stop the MONAI Label server by using Ctrl+C and then start the server again using the following command:

Copy
Copied!
            

monailabel start_server --app apps/radiology --studies datasets/Task09_Spleen/partially_labeled_imgs --conf models segmentation_spleen

Note

Now that you have a working MONAI Label implementation, work through our Quick Start guide and/or the resources available on the Next Steps page.

Note

If you are done with the MONAI Label lab, just close the browser window/tab


© Copyright 2022-2023, NVIDIA. Last updated on Apr 26, 2023.