From 08634fb7ef6d7088694aa525b3604c2b7b816ea2 Mon Sep 17 00:00:00 2001 From: Pratik Gandhi Date: Sun, 25 Oct 2026 01:07:05 -0700 Subject: [PATCH 1/3] Fix broken links and anchors in README files - nnunet/README.md: msd_datalist_generator.ipynb -> msd_crossval_datalist_generator.ipynb - bundle/introducing_config/README.md: ../get_started.md -> ../further_features.md - CONTRIBUTING.md: #ci-test-passing-guide -> #cicd-test-passing-guide - deployment/Triton/README.md: #model-config-file -> #model-config - reconstruction/MRI_reconstruction/{unet,varnet}_demo/README.md: #Acknowledgement -> #acknowledgment Signed-off-by: Pratik Gandhi --- CONTRIBUTING.md | 2 +- bundle/introducing_config/README.md | 2 +- deployment/Triton/README.md | 6 +++--- nnunet/README.md | 2 +- reconstruction/MRI_reconstruction/unet_demo/README.md | 2 +- reconstruction/MRI_reconstruction/varnet_demo/README.md | 2 +- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index e25df21625..137f18bcc6 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -186,7 +186,7 @@ By making a contribution to this project, I certify that: Once the changes are ready, push your local branch to the remote, e.g. `git push --set-upstream origin `, and [open a pull request](https://github.com/Project-MONAI/tutorials/pulls). When the pull request is opened, the MONAI repository has a set of GitHub actions that will run checks on the changes. -Please check more [details in the guidelines](#ci-test-passing-guide) for how to pass the tests. +Please check more [details in the guidelines](#cicd-test-passing-guide) for how to pass the tests. In addition, the team will perform diligent code reviews following this [set of guidelines](#common-recommendations-for-the-review) to reduce the amount of work for users to run the tutorials. diff --git a/bundle/introducing_config/README.md b/bundle/introducing_config/README.md index 31479a8140..3ae7cde30c 100644 --- a/bundle/introducing_config/README.md +++ b/bundle/introducing_config/README.md @@ -155,5 +155,5 @@ plt.show() - Running customized Python components (made available on the `PYTHONPATH`). - Overriding the component in `example.yaml` using, for example, `--id=new_value` in the command line. - Multiple configuration files and cross-file references. -- Replacing in terms of plain texts instead of Python objects ([tutorial](../get_started.md)). +- Replacing in terms of plain texts instead of Python objects ([tutorial](../further_features.md)). - The debugging mode to investigate the intermediate variables and results. diff --git a/deployment/Triton/README.md b/deployment/Triton/README.md index e5801f05a8..0e493280d2 100644 --- a/deployment/Triton/README.md +++ b/deployment/Triton/README.md @@ -69,7 +69,7 @@ any C++ code. We will use this to demonstrate implementing MONAI code inside Tri * [Quick Start](#quick-start) * [Examples](#examples) * [Usage](#usage) -* [Model Config File](#model-config-file) +* [Model Config File](#model-config) * [Error Hanldling](#error-handling) @@ -130,14 +130,14 @@ COPY models/monai_covid/1/model.py /models/monai_covid/1 ENTRYPOINT [ "tritonserver", "--model-repository=/models"] ``` -Note: The Triton service expects a certain directory structure discussed in [Model Config File](#model-config-file) to load the model definitions. +Note: The Triton service expects a certain directory structure discussed in [Model Config File](#model-config) to load the model definitions. 2. Next, the container with the Triton Service runs as a service (in background or separate terminal for demo). In this example, the ports used by the Triton Service are set to `8000` for client communications. ```Dockerfile: demo_app_image_name="monai_triton:demo" docker run --shm-size=128G --rm -p 127.0.0.1:8000:8000 -p 127.0.0.1:8001:8001 -p 127.0.0.1:8090:8002 ${demo_app_image_name} ``` -3. See [Model Config File](#model-config-file) to see the expected file structure for Triton. +3. See [Model Config File](#model-config) to see the expected file structure for Triton. - Modify the models/monai_prostrate/1/model.py file to satisfy any model configuration requirements while keeping the required components in the model definition. See the * [Usage](#usage) section for background. - In the models/monai_prostrate/1/config.pbtxt file configure the number of GPUs and which ones are used. e.g. Using two available GPUs and two parallel versions of the model per GPU diff --git a/nnunet/README.md b/nnunet/README.md index 0183797e09..d2cffd6dd5 100644 --- a/nnunet/README.md +++ b/nnunet/README.md @@ -52,7 +52,7 @@ The installation instruction is described [here](docs/install.md). The user needs to provide a data list (".json" file) for the new task and data root. In general, a valid data list needs to follow the format of the ones in [Medical Segmentation Decathlon (MSD)](https://drive.google.com/drive/folders/1HqEgzS8BV2c7xYNrZdEAnrHk7osJJ--2). -In [this tutorial](../auto3dseg/notebooks/msd_datalist_generator.ipynb), we provided example steps to download the [MSD Spleen dataset](http://medicaldecathlon.com) and prepare a datalist. +In [this tutorial](../auto3dseg/notebooks/msd_crossval_datalist_generator.ipynb), we provided example steps to download the [MSD Spleen dataset](http://medicaldecathlon.com) and prepare a datalist. Below we assume the dataset is downloaded to `/workspace/data/Task09_Spleen` and the datalist is in the current directory. ### Run with Minimal Input using ```nnUNetV2Runner``` diff --git a/reconstruction/MRI_reconstruction/unet_demo/README.md b/reconstruction/MRI_reconstruction/unet_demo/README.md index 526f7f0316..f34c0e9ade 100644 --- a/reconstruction/MRI_reconstruction/unet_demo/README.md +++ b/reconstruction/MRI_reconstruction/unet_demo/README.md @@ -19,7 +19,7 @@ This folder contains code to train and validate a U-Net for accelerated MRI reco * [Inference](#Inference) -* [Acknowledgment](#Acknowledgement) +* [Acknowledgment](#acknowledgment) *** diff --git a/reconstruction/MRI_reconstruction/varnet_demo/README.md b/reconstruction/MRI_reconstruction/varnet_demo/README.md index f21b43bda5..89ec05b164 100644 --- a/reconstruction/MRI_reconstruction/varnet_demo/README.md +++ b/reconstruction/MRI_reconstruction/varnet_demo/README.md @@ -19,7 +19,7 @@ This folder contains code to train and validate an e2e-VarNet ([https://arxiv.or * [Inference](#Inference) -* [Acknowledgment](#Acknowledgement) +* [Acknowledgment](#acknowledgment) *** From c2db924bd9b56e2719db5da2d07feaa6b94fe80d Mon Sep 17 00:00:00 2001 From: Pratik Gandhi Date: Mon, 26 Oct 2026 12:03:57 -0700 Subject: [PATCH 2/3] Address review: fix Triton code fence and anchors, full_gpu_inference_pipeline anchors, deepgrow stale link Signed-off-by: Pratik Gandhi --- deepgrow/ignite/README.md | 2 +- deployment/Triton/README.md | 3 +-- full_gpu_inference_pipeline/README.md | 6 +++--- 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/deepgrow/ignite/README.md b/deepgrow/ignite/README.md index d90b90aa1e..599308f53a 100644 --- a/deepgrow/ignite/README.md +++ b/deepgrow/ignite/README.md @@ -143,7 +143,7 @@ This notebook helps to run any pre-transforms before running inference over a De It also helps to run post-transforms to get the final label mask. -#### [Deepgrow Stats](./handler.py) +#### Deepgrow Stats It contains basic ignite handler to capture region/organ-wise statistics, save snapshots, outputs while running train/validation over a dataset that has multi-label mask. By-default the handler is added as part of training/validation steps. diff --git a/deployment/Triton/README.md b/deployment/Triton/README.md index 0e493280d2..aadd9b9be6 100644 --- a/deployment/Triton/README.md +++ b/deployment/Triton/README.md @@ -53,7 +53,7 @@ This demo and description borrows heavily from the [Triton Python Backend](https Get The Demo Source Code ------------------------------- -Pull down the demo repository and start with the [Quick Start] (#quick-start) guide. +Pull down the demo repository and start with the [Quick Start](#quick-start) guide. ``` $ git clone https://github.com/Project-MONAI/tutorials.git @@ -106,7 +106,6 @@ Alternatively, the user can just run the shell script provided the previous step $ ./mednist_client_run.sh ``` The expected result is variety of classification results for body images and local inference times. -``` ## Examples: The example demonstrates running a Triton Python Backend on a single image classification problem. diff --git a/full_gpu_inference_pipeline/README.md b/full_gpu_inference_pipeline/README.md index 4292aabdc4..82a9096c86 100644 --- a/full_gpu_inference_pipeline/README.md +++ b/full_gpu_inference_pipeline/README.md @@ -11,7 +11,7 @@ * [Benchmark](#benchmark) + [Understanding the benchmark output](#understanding-the-benchmark-output) + [HTTP vs. gRPC vs. shared memory](#http-vs-grpc-vs-shared-memory) - + [Pre/Post-processing on GPU vs. CPU](#pre-post-processing-on-gpu-vs-cpu) + + [Pre/Post-processing on GPU vs. CPU](#prepost-processing-on-gpu-vs-cpu) ## Overview @@ -57,7 +57,7 @@ Triton environment can be quickly setup by running a Triton docker container: docker run --gpus=1 -it --name='triton_monai' --ipc=host -p18100:8000 -p18101:8001 -p18102:8002 --shm-size=1g -v /yourfolderpath:/triton_monai nvcr.io/nvidia/tritonserver:21.12-py3 ``` Please note that when starting the docker container, --ipc=host should be set, so that shared memory can be used to do the data transmission between server and client. Also you should allocate a relatively large shared memory using --shm-size option, because starting from 21.04 release, Python backend uses shared memory to connect user's code to Triton. -### Setup python execution environment +### Setup python execution environment Since we will use MONAI transforms in Triton python backend, we should set up the python execution environment in Triton container by following the instructions in [Triton python backend repository](https://github.com/triton-inference-server/python_backend#using-custom-python-execution-environments). For the installation steps of MONAI, you can refer to [monai install](https://docs.monai.io/en/latest/installation.html "monai install"). Below are the steps used to setup the proper environments for this experiment: Install the software packages below: @@ -140,7 +140,7 @@ From the result, we can come to a conclusion that using shared memory will great ![](../figures/full_gpu_inference_figure1.png) -### Pre/Post-processing on GPU vs. CPU  +### Pre/Post-processing on GPU vs. CPU After doing pre and post-processing on GPU, we can get a 12x speedup for the full pipeline. ![](../figures/full_gpu_inference_figure2.png) From 7badb794f61dca9bc5fe129fdb7d17dfa6c25efd Mon Sep 17 00:00:00 2001 From: Pratik Gandhi Date: Wed, 28 Oct 2026 16:56:33 -0700 Subject: [PATCH 3/3] Fix diffusion unet tutorial link in maisi ControlNet notebook Signed-off-by: Pratik Gandhi --- generation/maisi/maisi_train_controlnet_tutorial.ipynb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/generation/maisi/maisi_train_controlnet_tutorial.ipynb b/generation/maisi/maisi_train_controlnet_tutorial.ipynb index 5cd17c6a2b..17bab0b876 100644 --- a/generation/maisi/maisi_train_controlnet_tutorial.ipynb +++ b/generation/maisi/maisi_train_controlnet_tutorial.ipynb @@ -348,7 +348,7 @@ "\n", "The training workflow requires one JSON file to specify the image embedding and segmentation pairs. In addtional, the diffusion model used in ControlNet necessitates additional input attributes, including output dimension, output spacing, and top/bottom body region. The dimensions, and spacing can be extracted from the header information of the training images. The pseudo whole-body segmentation mask, and the top/bottom body region inputs can be determined through manual examination or by utilizing segmentation masks from tools such as [TotalSegmentator](https://github.com/wasserth/TotalSegmentator) or [MONAI VISTA](https://github.com/Project-MONAI/VISTA). The body regions are formatted as 4-dimensional one-hot vectors: the head and neck region is represented by [1,0,0,0], the chest region by [0,1,0,0], the abdomen region by [0,0,1,0], and the lower body region (below the abdomen) by [0,0,0,1]. \n", "\n", - "To train the ControlNet/diffusion unet, we first store the latent features (image embeddings) produced by the autoencoder's encoder in local storage. This allows the latent diffusion model to directly utilize these features, thereby conserving both time and GPU memory during the training process. Additionally, we have provided the script for multi-GPU processing to save latent features from all training images, significantly accelerating the creation of the entire training set. Please check the Step 1 Create Training Data in [maisi_diff_unet_training_tutorial](./maisi_diff_unet_training_tutorial.ipynb) and [diff_model_create_training_data.py](./scripts/diff_model_create_training_data.py) for how to encode images and save as image embeddings.\n", + "To train the ControlNet/diffusion unet, we first store the latent features (image embeddings) produced by the autoencoder's encoder in local storage. This allows the latent diffusion model to directly utilize these features, thereby conserving both time and GPU memory during the training process. Additionally, we have provided the script for multi-GPU processing to save latent features from all training images, significantly accelerating the creation of the entire training set. Please check the Step 1 Create Training Data in [maisi_train_diff_unet_tutorial](./maisi_train_diff_unet_tutorial.ipynb) and [diff_model_create_training_data.py](./scripts/diff_model_create_training_data.py) for how to encode images and save as image embeddings.\n", "\n", "The JSON file used in ControlNet training has the following structure:" ]