Skip to content

Commit 3617388

Browse files
authored
Merge branch 'Project-MONAI:main' into main
2 parents 95f3387 + 476d2fc commit 3617388

24 files changed

+1188
-30
lines changed

.pre-commit-config.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ ci:
99

1010
repos:
1111
- repo: https://github.com/pre-commit/pre-commit-hooks
12-
rev: v4.6.0
12+
rev: v5.0.0
1313
hooks:
1414
- id: end-of-file-fixer
1515
- id: trailing-whitespace
@@ -23,7 +23,7 @@ repos:
2323
- id: detect-private-key
2424

2525
- repo: https://github.com/psf/black
26-
rev: "24.4.2"
26+
rev: "24.10.0"
2727
hooks:
2828
- id: black
2929
- id: black-jupyter

generation/2d_diffusion_autoencoder/2d_diffusion_autoencoder_tutorial.ipynb

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -474,9 +474,8 @@
474474
}
475475
],
476476
"source": [
477-
"max_epochs = (\n",
478-
" 1000 # training for longer (1e4 ~ 3h) helps a lot with reconstruction quality, even if the loss is already low\n",
479-
")\n",
477+
"# training for longer (1e4 ~ 3h) helps a lot with reconstruction quality, even if the loss is already low\n",
478+
"max_epochs = 1000\n",
480479
"val_interval = 100\n",
481480
"print_interval = 50\n",
482481
"iter_loss_list, val_iter_loss_list = [], []\n",

generation/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ Example shows the use cases of using MONAI to evaluate the performance of a gene
4343
## [Training a 2D VQ-VAE + Autoregressive Transformers](./2d_vqvae_transformer/2d_vqvae_transformer_tutorial.ipynb):
4444
Example shows how to train a Vector-Quantized Variation Autoencoder + Transformers on the MedNIST dataset.
4545

46-
## Training VQ-VAEs and VQ-GANs: [2D VAE](./2d_vqvae/2d_vqvae_tutorial.ipynb), [3D VAE](./3d_vqvae/3d_vqvae_tutorial.ipynb) and [2D GAN](./3d_autoencoderkl/2d_vqgan_tutorial.ipynb)
46+
## Training VQ-VAEs and VQ-GANs: [2D VAE](./2d_vqvae/2d_vqvae_tutorial.ipynb), [3D VAE](./3d_vqvae/3d_vqvae_tutorial.ipynb) and [2D GAN](./2d_vqgan/2d_vqgan_tutorial.ipynb)
4747
Examples show how to train Vector Quantized Variation Autoencoder on [2D](./2d_vqvae/2d_vqvae_tutorial.ipynb) and [3D](./3d_vqvae/3d_vqvae_tutorial.ipynb), and how to use the PatchDiscriminator class to train a [VQ-GAN](./2d_vqgan/2d_vqgan_tutorial.ipynb) and improve the quality of the generated images.
4848

4949
## [Training a 2D Denoising Diffusion Probabilistic Model](./2d_ddpm/2d_ddpm_tutorial.ipynb):

generation/anomaly_detection/2d_classifierfree_guidance_anomalydetection_tutorial.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -426,7 +426,7 @@
426426
},
427427
"source": [
428428
"condition_dropout = 0.15\n",
429-
"max_epochs = 2e4\n",
429+
"max_epochs = 20000\n",
430430
"batch_size = 64\n",
431431
"val_interval = 100\n",
432432
"iter_loss_list = []\n",

generation/maisi/README.md

Lines changed: 104 additions & 17 deletions
Large diffs are not rendered by default.
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{
2+
"num_output_samples": 1,
3+
"body_region": ["abdomen"],
4+
"anatomy_list": ["liver","hepatic tumor"],
5+
"controllable_anatomy_size": [],
6+
"num_inference_steps": 1000,
7+
"mask_generation_num_inference_steps": 1000,
8+
"output_size": [
9+
256,
10+
256,
11+
128
12+
],
13+
"image_output_ext": ".nii.gz",
14+
"label_output_ext": ".nii.gz",
15+
"spacing": [
16+
1.5,
17+
1.5,
18+
4.0
19+
],
20+
"autoencoder_sliding_window_infer_size": [96,96,96],
21+
"autoencoder_sliding_window_infer_overlap": 0.25,
22+
"autoencoder_tp_num_splits": 2
23+
}
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{
2+
"num_output_samples": 1,
3+
"body_region": ["abdomen"],
4+
"anatomy_list": ["liver","hepatic tumor"],
5+
"controllable_anatomy_size": [],
6+
"num_inference_steps": 1000,
7+
"mask_generation_num_inference_steps": 1000,
8+
"output_size": [
9+
256,
10+
256,
11+
256
12+
],
13+
"image_output_ext": ".nii.gz",
14+
"label_output_ext": ".nii.gz",
15+
"spacing": [
16+
1.5,
17+
1.5,
18+
2.0
19+
],
20+
"autoencoder_sliding_window_infer_size": [48,48,64],
21+
"autoencoder_sliding_window_infer_overlap": 0.25,
22+
"autoencoder_tp_num_splits": 2
23+
}
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{
2+
"num_output_samples": 1,
3+
"body_region": ["abdomen"],
4+
"anatomy_list": ["liver","hepatic tumor"],
5+
"controllable_anatomy_size": [],
6+
"num_inference_steps": 1000,
7+
"mask_generation_num_inference_steps": 1000,
8+
"output_size": [
9+
512,
10+
512,
11+
128
12+
],
13+
"image_output_ext": ".nii.gz",
14+
"label_output_ext": ".nii.gz",
15+
"spacing": [
16+
0.75,
17+
0.75,
18+
4.0
19+
],
20+
"autoencoder_sliding_window_infer_size": [64,64,32],
21+
"autoencoder_sliding_window_infer_overlap": 0.25,
22+
"autoencoder_tp_num_splits": 1
23+
}
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{
2+
"num_output_samples": 1,
3+
"body_region": ["abdomen"],
4+
"anatomy_list": ["liver","hepatic tumor"],
5+
"controllable_anatomy_size": [],
6+
"num_inference_steps": 1000,
7+
"mask_generation_num_inference_steps": 1000,
8+
"output_size": [
9+
256,
10+
256,
11+
256
12+
],
13+
"image_output_ext": ".nii.gz",
14+
"label_output_ext": ".nii.gz",
15+
"spacing": [
16+
1.5,
17+
1.5,
18+
2.0
19+
],
20+
"autoencoder_sliding_window_infer_size": [64,64,64],
21+
"autoencoder_sliding_window_infer_overlap": 0.25,
22+
"autoencoder_tp_num_splits": 4
23+
}
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{
2+
"num_output_samples": 1,
3+
"body_region": ["abdomen"],
4+
"anatomy_list": ["liver","hepatic tumor"],
5+
"controllable_anatomy_size": [],
6+
"num_inference_steps": 1000,
7+
"mask_generation_num_inference_steps": 1000,
8+
"output_size": [
9+
512,
10+
512,
11+
128
12+
],
13+
"image_output_ext": ".nii.gz",
14+
"label_output_ext": ".nii.gz",
15+
"spacing": [
16+
0.75,
17+
0.75,
18+
4.0
19+
],
20+
"autoencoder_sliding_window_infer_size": [80,80,32],
21+
"autoencoder_sliding_window_infer_overlap": 0.25,
22+
"autoencoder_tp_num_splits": 1
23+
}

0 commit comments

Comments
 (0)