Skip to content

Commit 90f39e4

Browse files
authored
Merge branch 'dev' into mednext
2 parents efe93b2 + 0bb20a8 commit 90f39e4

File tree

82 files changed

+515
-173
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

82 files changed

+515
-173
lines changed

.github/workflows/blossom-ci.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,7 @@ jobs:
3434
(
3535
github.actor == 'Nic-Ma' ||
3636
github.actor == 'wyli' ||
37-
github.actor == 'pxLi' ||
38-
github.actor == 'YanxuanLiu' ||
37+
github.actor == 'wendell-hom' ||
3938
github.actor == 'KumoLiu'
4039
)
4140
steps:

.github/workflows/cron.yml

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@ jobs:
1616
- "PT110+CUDA113"
1717
- "PT113+CUDA118"
1818
- "PT210+CUDA121"
19-
- "PTLATEST+CUDA124"
19+
- "PT240+CUDA126"
20+
- "PTLATEST+CUDA126"
2021
include:
2122
# https://docs.nvidia.com/deeplearning/frameworks/pytorch-release-notes
2223
- environment: PT110+CUDA113
@@ -28,9 +29,12 @@ jobs:
2829
- environment: PT210+CUDA121
2930
pytorch: "pytorch==2.1.0 torchvision==0.16.0 --extra-index-url https://download.pytorch.org/whl/cu121"
3031
base: "nvcr.io/nvidia/pytorch:23.08-py3" # CUDA 12.1
31-
- environment: PTLATEST+CUDA124
32+
- environment: PT240+CUDA126
33+
pytorch: "pytorch==2.4.0 torchvision==0.19.0 --extra-index-url https://download.pytorch.org/whl/cu121"
34+
base: "nvcr.io/nvidia/pytorch:24.08-py3" # CUDA 12.6
35+
- environment: PTLATEST+CUDA126
3236
pytorch: "-U torch torchvision --extra-index-url https://download.pytorch.org/whl/cu121"
33-
base: "nvcr.io/nvidia/pytorch:24.08-py3" # CUDA 12.4
37+
base: "nvcr.io/nvidia/pytorch:24.10-py3" # CUDA 12.6
3438
container:
3539
image: ${{ matrix.base }}
3640
options: "--gpus all"
@@ -80,7 +84,7 @@ jobs:
8084
if: github.repository == 'Project-MONAI/MONAI'
8185
strategy:
8286
matrix:
83-
container: ["pytorch:23.08", "pytorch:24.08"]
87+
container: ["pytorch:23.08", "pytorch:24.08", "pytorch:24.10"]
8488
container:
8589
image: nvcr.io/nvidia/${{ matrix.container }}-py3 # testing with the latest pytorch base image
8690
options: "--gpus all"
@@ -129,7 +133,7 @@ jobs:
129133
if: github.repository == 'Project-MONAI/MONAI'
130134
strategy:
131135
matrix:
132-
container: ["pytorch:24.08"]
136+
container: ["pytorch:24.10"]
133137
container:
134138
image: nvcr.io/nvidia/${{ matrix.container }}-py3 # testing with the latest pytorch base image
135139
options: "--gpus all"
@@ -233,7 +237,7 @@ jobs:
233237
if: github.repository == 'Project-MONAI/MONAI'
234238
needs: cron-gpu # so that monai itself is verified first
235239
container:
236-
image: nvcr.io/nvidia/pytorch:24.08-py3 # testing with the latest pytorch base image
240+
image: nvcr.io/nvidia/pytorch:24.10-py3 # testing with the latest pytorch base image
237241
options: "--gpus all --ipc=host"
238242
runs-on: [self-hosted, linux, x64, integration]
239243
steps:

.github/workflows/weekly-preview.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ jobs:
6666
export YEAR_WEEK=$(date +'%y%U')
6767
echo "Year week for tag is ${YEAR_WEEK}"
6868
if ! [[ $YEAR_WEEK =~ ^[0-9]{4}$ ]] ; then echo "Wrong 'year week' format. Should be 4 digits."; exit 1 ; fi
69-
git tag "1.4.dev${YEAR_WEEK}"
69+
git tag "1.5.dev${YEAR_WEEK}"
7070
git log -1
7171
git tag --list
7272
python setup.py sdist bdist_wheel

.pre-commit-config.yaml

Lines changed: 10 additions & 13 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
@@ -26,33 +26,30 @@ repos:
2626
args: ['--autofix', '--no-sort-keys', '--indent=4']
2727
- id: end-of-file-fixer
2828
- id: mixed-line-ending
29-
- repo: https://github.com/charliermarsh/ruff-pre-commit
30-
rev: v0.3.5
29+
- repo: https://github.com/astral-sh/ruff-pre-commit
30+
rev: v0.7.0
3131
hooks:
3232
- id: ruff
3333
args:
3434
- --fix
3535

3636
- repo: https://github.com/asottile/pyupgrade
37-
rev: v3.3.1
37+
rev: v3.19.0
3838
hooks:
3939
- id: pyupgrade
40-
args: [--py37-plus]
41-
name: Upgrade code excluding monai networks
40+
args: [--py39-plus, --keep-runtime-typing]
41+
name: Upgrade code with exceptions
4242
exclude: |
4343
(?x)(
4444
^versioneer.py|
4545
^monai/_version.py|
46-
^monai/networks/| # no PEP 604 for torchscript tensorrt
47-
^monai/losses/ # no PEP 604 for torchscript tensorrt
46+
^monai/networks/| # avoid typing rewrites
47+
^monai/apps/detection/utils/anchor_utils.py| # avoid typing rewrites
48+
^tests/test_compute_panoptic_quality.py # avoid typing rewrites
4849
)
49-
- id: pyupgrade
50-
args: [--py37-plus, --keep-runtime-typing]
51-
name: Upgrade monai networks
52-
files: (?x)(^monai/networks/)
5350
5451
- repo: https://github.com/asottile/yesqa
55-
rev: v1.4.0
52+
rev: v1.5.0
5653
hooks:
5754
- id: yesqa
5855
name: Unused noqa

CHANGELOG.md

Lines changed: 94 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,98 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).
55

66
## [Unreleased]
77

8+
## [1.4.0] - 2024-10-17
9+
## What's Changed
10+
### Added
11+
* Implemented Conjugate Gradient Solver to generate confidence maps. (#7876)
12+
* Added norm parameter to `ResNet` (#7752, #7805)
13+
* Introduced alpha parameter to `DiceFocalLoss` for improved flexibility (#7841)
14+
* Integrated Tailored ControlNet Implementations (#7875)
15+
* Integrated Tailored Auto-Encoder Model (#7861)
16+
* Integrated Tailored Diffusion U-Net Model (7867)
17+
* Added Maisi morphological functions (#7893)
18+
* Added support for downloading bundles from NGC private registry (#7907, #7929, #8076)
19+
* Integrated generative refactor into the core (#7886, #7962)
20+
* Made `ViT` and `UNETR` models compatible with TorchScript (#7937)
21+
* Implemented post-download checks for MONAI bundles and compatibility warnings (#7938)
22+
* Added NGC prefix argument when downloading bundles (#7974)
23+
* Added flash attention support in the attention block for improved performance (#7977)
24+
* Enhanced `MLPBlock` for compatibility with VISTA-3D (#7995)
25+
* Added support for Neighbor-Aware Calibration Loss (NACL) for calibrated models in segmentation tasks (#7819)
26+
* Added label_smoothing parameter to `DiceCELoss` for enhanced model calibration (#8000)
27+
* Add `include_fc` and `use_combined_linear` argument in the `SABlock` (#7996)
28+
* Added utilities, networks, and an inferer specific to VISTA-3D (#7999, #7987, #8047, #8059, #8021)
29+
* Integrated a new network, `CellSamWrapper`, for cell-based applications (#7981)
30+
* Introduced `WriteFileMapping` transform to map between input image paths and their corresponding output paths (#7769)
31+
* Added `TrtHandler` to accelerate models using TensorRT (#7990, #8064)
32+
* Added box and points conversion transforms for more flexible spatial manipulation (#8053)
33+
* Enhanced `RandSimulateLowResolutiond` transform with deterministic support (#8057)
34+
* Added a contiguous argument to the `Fourier` class to facilitate contiguous tensor outputs (#7969)
35+
* Allowed `ApplyTransformToPointsd` to receive a sequence of reference keys for more versatile point manipulation (#8063)
36+
* Made `MetaTensor` an optional print in `DataStats` and `DataStatsd` for more concise logging (#7814)
37+
#### misc.
38+
* Refactored Dataset to utilize Compose for handling transforms. (#7784)
39+
* Combined `map_classes_to_indices` and `generate_label_classes_crop_centers` into a unified function (#7712)
40+
* Introduced metadata schema directly into the codebase for improved structure and validation (#7409)
41+
* Renamed `optional_packages_version` to `required_packages_version` for clearer package dependency management. (#7253)
42+
* Replaced `pkg_resources` with the more modern packaging module for package handling (#7953)
43+
* Refactored MAISI-related networks to align with the new generative components (#7989, #7993, #8005)
44+
* Added a badge displaying monthly download statistics to enhance project visibility (#7891)
45+
### Fixed
46+
#### transforms
47+
* Ensured deterministic behavior in `MixUp`, `CutMix`, and `CutOut` transforms (#7813)
48+
* Applied a minor correction to `AsDiscrete` transform (#7984)
49+
* Fixed handling of integer weightmaps in `RandomWeightedCrop` (#8097)
50+
* Resolved data type bug in `ScaleIntensityRangePercentile` (#8109)
51+
#### data
52+
* Fixed negative strides issue in the `NrrdReader` (#7809)
53+
* Addressed wsireader issue with retrieving MPP (7921)
54+
* Ensured location is returned as a tuple in wsireader (#8007)
55+
* Corrected interpretation of space directions in nrrd reader (#8091)
56+
#### metrics and losses
57+
* Improved memory management for `NACLLoss` (#8020)
58+
* Fixed reduction logic in `GeneralizedDiceScore` (#7970)
59+
#### networks
60+
* Resolved issue with loading pre-trained weights in `ResNet` (#7924)
61+
* Fixed error where `torch.device` object had no attribute gpu_id during TensorRT export (#8019)
62+
* Corrected function for loading older weights in `DiffusionModelUNet` (#8031)
63+
* Switched to `torch_tensorrt.Device` instead of `torch.device` during TensorRT compilation (#8051)
64+
#### engines and handlers
65+
* Attempted to resolve the "experiment already exists" issue in `MLFlowHandler` (#7916)
66+
* Refactored the model export process for conversion and saving (#7934)
67+
#### misc.
68+
* Adjusted requirements to exclude Numpy version 2.0 (#7859)
69+
* Updated deprecated `scipy.ndimage` namespaces in optional imports (#7847, #7897)
70+
* Resolved `load_module()` deprecation in Python 3.12 (#7881)
71+
* Fixed Ruff type check issues (#7885)
72+
* Cleaned disk space in the conda test pipeline (#7902)
73+
* Replaced deprecated `pkgutil.find_loader` usage (#7906)
74+
* Enhanced docstrings in various modules (#7913, #8055)
75+
* Test cases fixing (#7905, #7794, #7808)
76+
* Fix mypy issue introduced in 1.11.0 (#7941)
77+
* Cleaned up warnings during test collection (#7914)
78+
* Fix incompatible types in assignment issue (#7950)
79+
* Fix outdated link in the docs (#7971)
80+
* Addressed CI issues (#7983, #8013)
81+
* Fix module can not import correctly issue (#8015)
82+
* Fix AttributeError when using torch.min and max (#8041)
83+
* Ensure synchronization by adding `cuda.synchronize` (#8058)
84+
* Ignore warning from nptyping as workaround (#8062)
85+
* Suppress deprecated warning when importing monai (#8067)
86+
* Fix link in test bundle under MONAI-extra-test-data (#8092)
87+
### Changed
88+
* Base Docker image upgraded to `nvcr.io/nvidia/pytorch:24.08-py3` from `nvcr.io/nvidia/pytorch:23.08-py3`
89+
* Change blossom-ci to ACL security format (#7843)
90+
* Move PyType test to weekly test (#8025)
91+
* Adjusted to meet Numpy 2.0 requirements (#7857)
92+
### Deprecated
93+
* Dropped support for Python 3.8 (#7909)
94+
* Remove deprecated arguments and class for v1.4 (#8079)
95+
### Removed
96+
* Remove use of deprecated python 3.12 strtobool (#7900)
97+
* Removed the pipeline for publishing to testpypi (#8086)
98+
* Cleaning up some very old and now obsolete infrastructure (#8113, #8118, #8121)
99+
8100
## [1.3.2] - 2024-06-25
9101
### Fixed
10102
#### misc.
@@ -1040,7 +1132,8 @@ the postprocessing steps should be used before calling the metrics methods
10401132

10411133
[highlights]: https://github.com/Project-MONAI/MONAI/blob/master/docs/source/highlights.md
10421134

1043-
[Unreleased]: https://github.com/Project-MONAI/MONAI/compare/1.3.2...HEAD
1135+
[Unreleased]: https://github.com/Project-MONAI/MONAI/compare/1.4.0...HEAD
1136+
[1.4.0]: https://github.com/Project-MONAI/MONAI/compare/1.3.2...1.4.0
10441137
[1.3.2]: https://github.com/Project-MONAI/MONAI/compare/1.3.1...1.3.2
10451138
[1.3.1]: https://github.com/Project-MONAI/MONAI/compare/1.3.0...1.3.1
10461139
[1.3.0]: https://github.com/Project-MONAI/MONAI/compare/1.2.0...1.3.0

CITATION.cff

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ title: "MONAI: Medical Open Network for AI"
66
abstract: "AI Toolkit for Healthcare Imaging"
77
authors:
88
- name: "MONAI Consortium"
9-
date-released: 2024-06-26
10-
version: "1.3.2"
9+
date-released: 2024-10-17
10+
version: "1.4.0"
1111
identifiers:
1212
- description: "This DOI represents all versions of MONAI, and will always resolve to the latest one."
1313
type: doi

CONTRIBUTING.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -383,3 +383,8 @@ then make PRs to the `releasing/[version number]` to fix the bugs via the regula
383383
If any error occurs after the release process, first check out a new hotfix branch from the `main` branch,
384384
make a patch version release following the semantic versioning, for example, `releasing/0.1.1`.
385385
Make sure the `releasing/0.1.1` is merged back into both `dev` and `main` and all the test pipelines succeed.
386+
387+
388+
<p align="right">
389+
<a href="#introduction">⬆️ Back to Top</a>
390+
</p>

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
# To build with a different base image
1313
# please run `docker build` using the `--build-arg PYTORCH_IMAGE=...` flag.
14-
ARG PYTORCH_IMAGE=nvcr.io/nvidia/pytorch:24.08-py3
14+
ARG PYTORCH_IMAGE=nvcr.io/nvidia/pytorch:24.10-py3
1515
FROM ${PYTORCH_IMAGE}
1616

1717
LABEL maintainer="[email protected]"

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,11 @@
1616
[![codecov](https://codecov.io/gh/Project-MONAI/MONAI/branch/dev/graph/badge.svg?token=6FTC7U1JJ4)](https://codecov.io/gh/Project-MONAI/MONAI)
1717
[![monai Downloads Last Month](https://assets.piptrends.com/get-last-month-downloads-badge/monai.svg 'monai Downloads Last Month by pip Trends')](https://piptrends.com/package/monai)
1818

19-
MONAI is a [PyTorch](https://pytorch.org/)-based, [open-source](https://github.com/Project-MONAI/MONAI/blob/dev/LICENSE) framework for deep learning in healthcare imaging, part of [PyTorch Ecosystem](https://pytorch.org/ecosystem/).
20-
Its ambitions are:
21-
- developing a community of academic, industrial and clinical researchers collaborating on a common foundation;
22-
- creating state-of-the-art, end-to-end training workflows for healthcare imaging;
23-
- providing researchers with the optimized and standardized way to create and evaluate deep learning models.
19+
MONAI is a [PyTorch](https://pytorch.org/)-based, [open-source](https://github.com/Project-MONAI/MONAI/blob/dev/LICENSE) framework for deep learning in healthcare imaging, part of the [PyTorch Ecosystem](https://pytorch.org/ecosystem/).
20+
Its ambitions are as follows:
21+
- Developing a community of academic, industrial and clinical researchers collaborating on a common foundation;
22+
- Creating state-of-the-art, end-to-end training workflows for healthcare imaging;
23+
- Providing researchers with the optimized and standardized way to create and evaluate deep learning models.
2424

2525

2626
## Features

docs/images/maisi_train.png

183 KB
Loading

0 commit comments

Comments
 (0)