-
Notifications
You must be signed in to change notification settings - Fork 740
Hecktor22 tutorial #1107
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Hecktor22 tutorial #1107
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
378c123
hecktor tutorial
myron 7864592
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] 50efdcd
more info
myron 5764726
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] 94b21e5
Merge branch 'main' into hktr22
myron 6872130
format
myron 0959ea6
format
myron 98ca127
small
myron File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
|
||
# HECKTOR22 | ||
|
||
|
||
The HECKTOR22 dataset is from MICCAI 2022 challenge **[HEad and NeCK TumOR Segmentation and Outcome Prediction (HECKTOR22)](https://hecktor.grand-challenge.org)**. The solution described here won the 1st place in the HECKTOR22 challenge [(NVAUTO team)](https://hecktor.grand-challenge.org/final-leaderboard/): | ||
|
||
Andriy Myronenko, Md Mahfuzur Rahman Siddiquee, Dong Yang, Yufan He and Daguang Xu: "Automated head and neck tumor segmentation from 3D PET/CT". In MICCAI (2022). [arXiv](https://arxiv.org/abs/2209.10809) | ||
|
||
 | ||
|
||
## Task overview | ||
|
||
The task is to segment 3D Head and Neck (H&N) tumors and lymph nodes classes from a pair of 3D CT and PET images. The ground truth labels are provided for 524 cases with average 3D CT size of 512x512x200 voxels at 0.98x0.98x3 mm average resolution, and with average 3D PET size of 200x200x200 voxels at 4x4x4 mm. The CT and PET images where rigidly aligned to a common origin, but remain at different sizes and resolutions. | ||
|
||
|
||
## Auto3DSeg | ||
|
||
The HECKTOR22 tutorial is only supported for **SegResNet** algo (since currently it is the only algo with support of multi-resolution input images, such as CT and PET). | ||
Auto3DSeg runs a full workflow including data analysis, and multi-fold training. Please download the dataset into /data/hecktor22 folder first. | ||
|
||
|
||
### Running based on the input config | ||
|
||
The Auto3DSeg can be run using a config **input.yaml** | ||
|
||
```bash | ||
python -m monai.apps.auto3dseg AutoRunner run --input='./input.yaml' --algos='segresnet' | ||
``` | ||
|
||
### Running from python | ||
|
||
Alternatively you can also run Auto3DSeg from a python script, where you can customize more options. Please see the comments in **hecktor22.py** | ||
```bash | ||
python hecktor22.py | ||
``` | ||
|
||
|
||
## Validation performance: NVIDIA DGX-1 (8x V100 16G) | ||
|
||
The validation results can be obtained by running the training script with MONAI 1.1.0 on NVIDIA DGX-1 with (8x V100 16GB) GPUs. The results below are in terms of **Aggregated Dice**, which was used as the key metric in the challenge [1,2]. The values of the Aggregated Dice slightly differ from a conventional average Dice (which is used by Auto3DSeg by default for all tasks). | ||
|
||
|
||
| | Fold 0 | Fold 1 | Fold 2 | Fold 3 | Fold 4 | Avg | | ||
|:------:|:------:|:------:|:------:|:------:|:------:|:---:| | ||
| SegResNet | 0.7933 | 0.7862 | 0.7816 |0.8275 | 0.8059 | 0.7989 | | ||
|
||
|
||
## Data | ||
|
||
The HECKTOR22 challenge dataset [2,3] can be downloaded from [here](https://hecktor.grand-challenge.org) after the registration. Each user is responsible for checking the content of the datasets and the applicable licenses and determining if suitable for the intended use. The license for the HECKTOR22 dataset is different than MONAI license. | ||
|
||
## References | ||
[1] Andriy Myronenko, Md Mahfuzur Rahman Siddiquee, Dong Yang, Yufan He and Daguang Xu: "Automated head and neck tumor segmentation from 3D PET/CT". In MICCAI (2022). https://arxiv.org/abs/2209.10809 | ||
|
||
[2] Andrearczyk, V., Oreiller, V., Boughdad, S., Rest, C.C.L., Elhalawani, H., Jreige, M., Prior, J.O., Valli`eres, M., Visvikis, D., Hatt, M., Depeursinge, A.: Overview of the HECKTOR Challenge at MICCAI 2022: Automatic Head and Neck Tumor Segmentation and Outcome Prediction in PET/CT (2023), https://arxiv.org/abs/2201.04138 | ||
|
||
[3] Oreiller, V., Andrearczyk, V., Jreige, M., Boughdad, S., Elhalawani, H., Castelli, J., Valli`eres, M., Zhu, S., Xie, J., Peng, Y., Iantsen, A., Hatt, M., Yuan, Y., Ma, J., Yang, X., Rao, C., Pai, S., Ghimire, K., Feng, X. Naser, M.A., Fuller, C.D., Yousefirizi, F., Rahmim, A., Chen, H., Wang, L., Prior, J.O., Depeursinge, A.: Head and neck tumor segmentation in PET/CT: The HECKTOR challenge. Medical Image Analysis 77, 102336 (2022) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# Copyright (c) MONAI Consortium | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
from monai.apps.auto3dseg import AutoRunner | ||
myron marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
# the minimum required code is to create an AutoRunner() and call runner.run() | ||
# the algos must be set to 'segresnet' (since currently it's the only algo with support of multi-resolution input images, such as CT and PET) | ||
myron marked this conversation as resolved.
Show resolved
Hide resolved
|
||
# here we also set ensemble=False (optional) to prevent inference on the testing set (since we do not use any testing sets, only the 5-fold cross validation) | ||
# for you own inference (and ensemble) you can provide a list of testing files in "hecktor22_folds.json" | ||
runner = AutoRunner(input='input.yaml', algos = 'segresnet', work_dir= './work_dir', ensemble=False) | ||
|
||
## optionally, we can use just 1-fold (for a quick training of a single model, instead of training 5 folds) | ||
# runner.set_num_fold(1) | ||
|
||
## optionally, we can define the path to the dataset here, instead of the one in input.yaml | ||
#runner.set_training_params({"dataroot" : '/data/hecktor22'}) | ||
|
||
runner.run() |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.