Skip to content

Commit

Permalink
Merge pull request #429 from Project-MONAI/dev
Browse files Browse the repository at this point in the history
merge master
  • Loading branch information
Nic-Ma authored Jul 8, 2022
2 parents ec463d6 + e270741 commit ca62306
Show file tree
Hide file tree
Showing 532 changed files with 33,258 additions and 7,547 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,11 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v2
uses: actions/checkout@v3

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
uses: github/codeql-action/init@v2
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
Expand All @@ -53,7 +53,7 @@ jobs:
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
# - name: Autobuild
# uses: github/codeql-action/autobuild@v1
# uses: github/codeql-action/autobuild@v2

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl
Expand All @@ -68,4 +68,4 @@ jobs:
BUILD_MONAI=1 ./runtests.sh --build
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
uses: github/codeql-action/analyze@v2
2 changes: 1 addition & 1 deletion .github/workflows/conda.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
minimum-size: 8
maximum-size: 16
disk-root: "D:"
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/cron-mmar.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,16 @@ jobs:
if: github.repository == 'Project-MONAI/MONAI'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Set up Python 3.8
uses: actions/setup-python@v2
uses: actions/setup-python@v3
with:
python-version: 3.8
- name: cache weekly timestamp
id: pip-cache
run: echo "::set-output name=datew::$(date '+%Y-%V')"
- name: cache for pip
uses: actions/cache@v2
uses: actions/cache@v3
id: cache
with:
path: ~/.cache/pip
Expand Down
30 changes: 15 additions & 15 deletions .github/workflows/cron.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,24 +15,24 @@ jobs:
runs-on: [self-hosted, linux, x64, common]
strategy:
matrix:
pytorch-version: [1.6.0, 1.7.1, 1.8.1, 1.9.1, latest]
pytorch-version: [1.7.1, 1.8.1, 1.9.1, 1.10.2, latest]
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Install the dependencies
run: |
which python
python -m pip install --upgrade pip wheel
python -m pip uninstall -y torch torchvision
if [ ${{ matrix.pytorch-version }} == "latest" ]; then
python -m pip install torch torchvision
elif [ ${{ matrix.pytorch-version }} == "1.6.0" ]; then
python -m pip install torch==1.6.0 torchvision==0.7.0
python -m pip install torch torchvision --extra-index-url https://download.pytorch.org/whl/cu113
elif [ ${{ matrix.pytorch-version }} == "1.7.1" ]; then
python -m pip install torch==1.7.1 torchvision==0.8.2
python -m pip install torch==1.7.1 torchvision==0.8.2 --extra-index-url https://download.pytorch.org/whl/cu113
elif [ ${{ matrix.pytorch-version }} == "1.8.1" ]; then
python -m pip install torch==1.8.1 torchvision==0.9.1
python -m pip install torch==1.8.1 torchvision==0.9.1 --extra-index-url https://download.pytorch.org/whl/cu113
elif [ ${{ matrix.pytorch-version }} == "1.9.1" ]; then
python -m pip install torch==1.9.1 torchvision==0.10.1
python -m pip install torch==1.9.1 torchvision==0.10.1 --extra-index-url https://download.pytorch.org/whl/cu113
elif [ ${{ matrix.pytorch-version }} == "1.10.2" ]; then
python -m pip install torch==1.10.2 torchvision==0.11.3 --extra-index-url https://download.pytorch.org/whl/cu113
fi
python -m pip install -r requirements-dev.txt
python -m pip list
Expand Down Expand Up @@ -62,13 +62,13 @@ jobs:
if: github.repository == 'Project-MONAI/MONAI'
strategy:
matrix:
container: ["pytorch:21.02", "pytorch:21.10", "pytorch:22.03"] # 21.02, 21.10 for backward comp.
container: ["pytorch:21.02", "pytorch:21.10", "pytorch:22.06"] # 21.02, 21.10 for backward comp.
container:
image: nvcr.io/nvidia/${{ matrix.container }}-py3 # testing with the latest pytorch base image
options: "--gpus all"
runs-on: [self-hosted, linux, x64, common]
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Install APT dependencies
run: |
apt-get update
Expand Down Expand Up @@ -106,13 +106,13 @@ jobs:
if: github.repository == 'Project-MONAI/MONAI'
strategy:
matrix:
container: ["pytorch:21.02", "pytorch:21.10", "pytorch:22.03"] # 21.02, 21.10 for backward comp.
container: ["pytorch:21.02", "pytorch:21.10", "pytorch:22.06"] # 21.02, 21.10 for backward comp.
container:
image: nvcr.io/nvidia/${{ matrix.container }}-py3 # testing with the latest pytorch base image
options: "--gpus all"
runs-on: [self-hosted, linux, x64, common]
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Install the dependencies
Expand Down Expand Up @@ -204,11 +204,11 @@ jobs:
if: github.repository == 'Project-MONAI/MONAI'
needs: cron-gpu # so that monai itself is verified first
container:
image: nvcr.io/nvidia/pytorch:22.03-py3 # testing with the latest pytorch base image
image: nvcr.io/nvidia/pytorch:22.06-py3 # testing with the latest pytorch base image
options: "--gpus all --ipc=host"
runs-on: [self-hosted, linux, x64, common]
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Install MONAI
id: monai-install
run: |
Expand All @@ -223,7 +223,7 @@ jobs:
- name: Checkout tutorials and install their requirements
run: |
cd /opt
git clone --depth 1 --branch master --single-branch https://github.com/Project-MONAI/tutorials.git # latest commit of master branch
git clone --depth 1 --branch main --single-branch https://github.com/Project-MONAI/tutorials.git # latest commit of main branch
cd tutorials
python -m pip install -r requirements.txt
- name: Run tutorial notebooks
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,13 @@ jobs:
if: github.repository == 'Project-MONAI/MONAI'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
# full history so that we can git describe
with:
ref: dev
fetch-depth: 0
- name: Set up Python 3.8
uses: actions/setup-python@v2
uses: actions/setup-python@v3
with:
python-version: 3.8
- shell: bash
Expand All @@ -50,7 +50,7 @@ jobs:
needs: versioning_dev
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
ref: dev
- name: Download version
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ on:
jobs:
integration-py3:
container:
image: nvcr.io/nvidia/pytorch:21.12-py3 # CUDA 11.5
options: --gpus all
image: nvcr.io/nvidia/pytorch:22.04-py3 # CUDA 11.6
options: --gpus all # shm-size 4g works fine
runs-on: [self-hosted, linux, x64, common]
steps:
# checkout the pull request branch
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
token: ${{ secrets.PR_MAINTAIN }}
repository: ${{ github.event.client_payload.pull_request.head.repo.full_name }}
Expand All @@ -22,7 +22,7 @@ jobs:
run: |
echo "::set-output name=datew::$(date '+%Y-%V')"
- name: cache for pip
uses: actions/cache@v2
uses: actions/cache@v3
id: cache
with:
path: |
Expand All @@ -34,7 +34,7 @@ jobs:
which python
python -m pip install --upgrade pip wheel
python -m pip uninstall -y torch torchvision
python -m pip install torch==1.11.0+cu115 torchvision==0.12.0+cu115 -f https://download.pytorch.org/whl/torch_stable.html
python -m pip install torch==1.12.0+cu116 torchvision==0.13.0+cu116 -f https://download.pytorch.org/whl/torch_stable.html
python -m pip install -r requirements-dev.txt
rm -rf /github/home/.cache/torch/hub/mmars/
- name: Run integration tests
Expand Down
30 changes: 19 additions & 11 deletions .github/workflows/pythonapp-gpu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,17 @@ jobs:
- "PT17+CUDA102"
- "PT18+CUDA102"
- "PT18+CUDA112"
- "PT111+CUDA116"
- "PT112+CUDA116"
- "PT110+CUDA102"
- "PT111+CUDA102"
- "PT112+CUDA102"
include:
# https://docs.nvidia.com/deeplearning/frameworks/pytorch-release-notes
- environment: PT17+CUDA102
pytorch: "torch==1.7.1 torchvision==0.8.2"
base: "nvcr.io/nvidia/cuda:10.2-devel-ubuntu18.04"
- environment: PT18+CUDA102
pytorch: "torch==1.8.1 torchvision==0.9.1"
# pytorch 1.8.2 LTS
pytorch: "torch==1.8.2 torchvision==0.9.2 --extra-index-url https://download.pytorch.org/whl/lts/1.8/cu102"
base: "nvcr.io/nvidia/cuda:10.2-devel-ubuntu18.04"
- environment: PT18+CUDA112
# we explicitly set pytorch to -h to avoid pip install error
Expand All @@ -44,29 +45,36 @@ jobs:
# 21.10: 1.10.0a0+0aef44c
pytorch: "-h"
base: "nvcr.io/nvidia/pytorch:21.10-py3"
- environment: PT111+CUDA116
- environment: PT112+CUDA116
# we explicitly set pytorch to -h to avoid pip install error
# 22.03: 1.12.0a0+2c916ef
# 22.06: 1.13.0a0+340c412
pytorch: "-h"
base: "nvcr.io/nvidia/pytorch:22.03-py3"
base: "nvcr.io/nvidia/pytorch:22.06-py3"
- environment: PT110+CUDA102
pytorch: "torch==1.10.1 torchvision==0.11.2"
pytorch: "torch==1.10.2 torchvision==0.11.3"
base: "nvcr.io/nvidia/cuda:10.2-devel-ubuntu18.04"
- environment: PT111+CUDA102
pytorch: "torch==1.11.0 torchvision==0.12.0"
- environment: PT112+CUDA102
pytorch: "torch==1.12.0 torchvision==0.13.0"
base: "nvcr.io/nvidia/cuda:10.2-devel-ubuntu18.04"
container:
image: ${{ matrix.base }}
options: --gpus all
runs-on: [self-hosted, linux, x64, common]
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: apt install
run: |
# workaround for https://github.com/Project-MONAI/MONAI/issues/4200
apt-key del 7fa2af80 && rm -rf /etc/apt/sources.list.d/nvidia-ml.list /etc/apt/sources.list.d/cuda.list
apt-get update
apt-get install -y wget
wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64/cuda-keyring_1.0-1_all.deb
dpkg -i cuda-keyring_1.0-1_all.deb
if [ ${{ matrix.environment }} = "PT17+CUDA102" ] || \
[ ${{ matrix.environment }} = "PT18+CUDA102" ] || \
[ ${{ matrix.environment }} = "PT110+CUDA102" ] || \
[ ${{ matrix.environment }} = "PT111+CUDA102" ]
[ ${{ matrix.environment }} = "PT112+CUDA102" ]
then
PYVER=3.7 PYSFX=3 DISTUTILS=python3-distutils && \
apt-get update && apt-get install -y --no-install-recommends \
Expand Down
38 changes: 19 additions & 19 deletions .github/workflows/pythonapp-min.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@ jobs:
os: [windows-latest, macOS-latest, ubuntu-latest]
timeout-minutes: 40
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Set up Python 3.8
uses: actions/setup-python@v2
uses: actions/setup-python@v3
with:
python-version: 3.8
- name: Prepare pip wheel
Expand All @@ -43,19 +43,19 @@ jobs:
echo "::set-output name=dir::$(pip cache dir)"
shell: bash
- name: cache for pip
uses: actions/cache@v2
uses: actions/cache@v3
id: cache
with:
path: ${{ steps.pip-cache.outputs.dir }}
key: ${{ matrix.os }}-latest-pip-${{ steps.pip-cache.outputs.datew }}
- if: runner.os == 'windows'
name: Install torch cpu from pytorch.org (Windows only)
run: |
python -m pip install torch==1.11.0+cpu -f https://download.pytorch.org/whl/torch_stable.html
python -m pip install torch==1.12.0+cpu -f https://download.pytorch.org/whl/torch_stable.html
- name: Install the dependencies
run: |
# min. requirements
python -m pip install torch==1.11.0
python -m pip install torch==1.12.0
python -m pip install -r requirements-min.txt
python -m pip list
BUILD_MONAI=0 python setup.py develop # no compile of extensions
Expand All @@ -77,9 +77,9 @@ jobs:
python-version: [3.7, 3.8, 3.9]
timeout-minutes: 40
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Prepare pip wheel
Expand All @@ -93,15 +93,15 @@ jobs:
echo "::set-output name=dir::$(pip cache dir)"
shell: bash
- name: cache for pip
uses: actions/cache@v2
uses: actions/cache@v3
id: cache
with:
path: ${{ steps.pip-cache.outputs.dir }}
key: ubuntu-latest-latest-pip-${{ steps.pip-cache.outputs.datew }}
- name: Install the dependencies
run: |
# min. requirements
python -m pip install torch==1.11.0
python -m pip install torch==1.12.0
python -m pip install -r requirements-min.txt
python -m pip list
BUILD_MONAI=0 python setup.py develop # no compile of extensions
Expand All @@ -119,12 +119,12 @@ jobs:
strategy:
fail-fast: false
matrix:
pytorch-version: [1.6.0, 1.7.1, 1.8.1, 1.9.1, 1.10.1, latest]
pytorch-version: [1.7.1, 1.8.2, 1.9.1, 1.10.2, 1.11.0, latest]
timeout-minutes: 40
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Set up Python 3.8
uses: actions/setup-python@v2
uses: actions/setup-python@v3
with:
python-version: 3.8
- name: Prepare pip wheel
Expand All @@ -138,7 +138,7 @@ jobs:
echo "::set-output name=dir::$(pip cache dir)"
shell: bash
- name: cache for pip
uses: actions/cache@v2
uses: actions/cache@v3
id: cache
with:
path: ${{ steps.pip-cache.outputs.dir }}
Expand All @@ -148,16 +148,16 @@ jobs:
# min. requirements
if [ ${{ matrix.pytorch-version }} == "latest" ]; then
python -m pip install torch
elif [ ${{ matrix.pytorch-version }} == "1.6.0" ]; then
python -m pip install torch==1.6.0
elif [ ${{ matrix.pytorch-version }} == "1.7.1" ]; then
python -m pip install torch==1.7.1
elif [ ${{ matrix.pytorch-version }} == "1.8.1" ]; then
python -m pip install torch==1.8.1
elif [ ${{ matrix.pytorch-version }} == "1.8.2" ]; then
python -m pip install torch==1.8.2 --extra-index-url https://download.pytorch.org/whl/lts/1.8/cpu
elif [ ${{ matrix.pytorch-version }} == "1.9.1" ]; then
python -m pip install torch==1.9.1
elif [ ${{ matrix.pytorch-version }} == "1.10.1" ]; then
python -m pip install torch==1.10.1
elif [ ${{ matrix.pytorch-version }} == "1.10.2" ]; then
python -m pip install torch==1.10.2
elif [ ${{ matrix.pytorch-version }} == "1.11.0" ]; then
python -m pip install torch==1.11.0
fi
python -m pip install -r requirements-min.txt
python -m pip list
Expand Down
Loading

0 comments on commit ca62306

Please sign in to comment.