Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
85 commits
Select commit Hold shift + click to select a range
46c1a4c
Enhance csrc/resample (#1471)
wyli Feb 24, 2021
3a1c459
move transforms out of compose file (#1623)
rijobro Feb 24, 2021
c98fe05
pad_list_data_collate (#1626)
rijobro Feb 24, 2021
69d9fcc
decollate batch (#1624)
rijobro Feb 25, 2021
b2f1cf4
enhance random range parameters (#1635)
rijobro Feb 25, 2021
3c45f18
Loss script fixes (#1645)
ericspod Feb 25, 2021
9ae3005
1633 fix string length > 1024 issue in all_gather (#1634)
Nic-Ma Feb 25, 2021
f83e300
1567 add RemoveRepeatedChannel (#1569)
leotam Feb 25, 2021
c68d25e
[DLMED] add progress arg (#1647)
Nic-Ma Feb 25, 2021
5875ae6
1650-update distcall (#1652)
wyli Feb 25, 2021
56c5402
Fix ToPIL (#1648)
bhashemian Feb 26, 2021
1df6352
Randomizable constructor (#1639)
rijobro Feb 26, 2021
4b8819a
Add more tests to test_deepgrow_dataset (#1654)
YuanTingHsieh Feb 27, 2021
39fd455
Add Deepgrow inference transforms (#1653)
YuanTingHsieh Mar 1, 2021
f5ccdc6
1668 Add RandAxisFlip transforms (#1670)
Nic-Ma Mar 1, 2021
20e17b2
allow dictionary image only and test endianness (#1669)
rijobro Mar 2, 2021
9898a89
1673 Add AutoAdjustChannel transform (#1675)
Nic-Ma Mar 2, 2021
421c0a9
[1662] Allow missing keys (#1676)
rijobro Mar 3, 2021
27543c8
nifti saver squeeze dims (#1680)
rijobro Mar 3, 2021
b533afd
improve gradcam doc (#1682)
rijobro Mar 3, 2021
7cfb529
fixes integration tests (#1683)
wyli Mar 3, 2021
4bd9cf3
Update load pretrain for densenet (#1684)
yiheng-wang-nv Mar 3, 2021
8cc200f
revise the dtype according to the discussion (#1671)
wyli Mar 3, 2021
ac9f953
Fix senet pretrained weights issue (#1689)
yiheng-wang-nv Mar 4, 2021
380f042
1680 Add squeeze SegmentationSaver handler (#1686)
Nic-Ma Mar 4, 2021
114faf0
1285 adds module list (#1690)
wyli Mar 4, 2021
0bd86b1
1685-upgrade base image to 21.02 (#1687)
wyli Mar 4, 2021
75b5772
fixes data type in switching (#1694)
wyli Mar 5, 2021
889c9f9
WSI reader (#1548)
bhashemian Mar 5, 2021
232e8a5
[DLMED] add WSIReader to LoadImage (#1695)
Nic-Ma Mar 5, 2021
66811fe
Raise import error for openslide and cuimage (#1699)
bhashemian Mar 7, 2021
b25b3d3
1604 Revise docstring cam (#1705)
wyli Mar 8, 2021
ce6628a
1704 Add Affined transform (#1709)
Nic-Ma Mar 8, 2021
133f42a
1693 update for pytorch 1.8 (#1700)
wyli Mar 8, 2021
634b32d
[DLMED] update datasets (#1712)
Nic-Ma Mar 8, 2021
08af0cc
with allow_missing_keys_mode (#1714)
rijobro Mar 8, 2021
f4560a1
update links (#1717)
wyli Mar 8, 2021
cbddce9
1500-update grid dataset to support patch level transforms (#1679)
wyli Mar 8, 2021
0751ca0
Update DataLoader arg type of workflow (#1719)
Nic-Ma Mar 9, 2021
78ec66f
1651 implement RegUNet (#1658)
kate-sann5100 Mar 9, 2021
ea1d04b
remove print msg (#1730)
wyli Mar 9, 2021
a462714
Fix MONAI docker dependency (#1731)
bhashemian Mar 9, 2021
d4c201e
[1710] Gradcam eval (#1734)
rijobro Mar 10, 2021
c362beb
fixes unit test (#1735)
wyli Mar 10, 2021
0b1fc4e
basic inverse API (#1720)
rijobro Mar 10, 2021
c3e5a69
improve decollate test for set_determinism (#1736)
rijobro Mar 10, 2021
6d3bf2f
1236 integration test memory (#1738)
wyli Mar 11, 2021
401ea29
1541 update coverage report config (#1746)
wyli Mar 11, 2021
ce8f92a
1665 adjust localnet (#1752)
kate-sann5100 Mar 12, 2021
abf8a99
1651 globalnet (#1729)
kate-sann5100 Mar 12, 2021
e001d2a
[DLMED] update WSIReader for typos and docs (#1758)
Nic-Ma Mar 12, 2021
21a3c16
1742 Add DistributedWeightedRandomSampler (#1745)
Nic-Ma Mar 12, 2021
f56058d
Croppad inverse transform (#1737)
rijobro Mar 13, 2021
e17e158
TEST: Fix failing pytype check for predict_segmentation (#1762)
adamaji Mar 13, 2021
42e963f
BUG: MedNISTDataset returns differently sized datasets for different …
adamaji Mar 14, 2021
4670fd2
Add __len__ for DistributedWeightedRandomSampler (#1766)
Nic-Ma Mar 15, 2021
1badb41
reduce randomly cropped amount to appease CI (#1769)
rijobro Mar 15, 2021
e5726d1
1756 update ignite version to 0.4.4 (#1759)
Nic-Ma Mar 15, 2021
3ea9ed4
update contrib guide to include some recent changes in dev tools (#1763)
wyli Mar 16, 2021
13a2c59
1768 Update docs based on feedback (#1774)
Nic-Ma Mar 16, 2021
3406398
lossless inverse (#1767)
rijobro Mar 16, 2021
43d9582
1776 Add support for new arg `greater_or_equal` from ignite 0.4.4 (#1…
Nic-Ma Mar 16, 2021
050efb7
1757 Enhance CheckpointLoader to restore max_epochs (#1775)
Nic-Ma Mar 16, 2021
bcbd685
Update WSIReader with cuCIM (#1773)
bhashemian Mar 16, 2021
5588528
Inverse Spacingd (#1779)
rijobro Mar 16, 2021
b868087
1755 improve focal loss (#1765)
yiheng-wang-nv Mar 17, 2021
46154ec
Inverse Resized (#1780)
rijobro Mar 17, 2021
cf3bd1a
Inverse Zoomd and RandZoomd (#1778)
rijobro Mar 17, 2021
592806a
Inverse Rotated (#1782)
rijobro Mar 17, 2021
7f0e789
Inverse Affined and RandAffined (#1781)
rijobro Mar 17, 2021
053d0c8
Fix type error (#1792)
yiheng-wang-nv Mar 17, 2021
f063a47
Update cucim to remove warning message (#1799)
bhashemian Mar 18, 2021
466a0bf
Implement FROC metric (#1509)
yiheng-wang-nv Mar 18, 2021
86cbf05
[1798] fix RandZoomd collation (#1801)
rijobro Mar 18, 2021
4411758
Remove WSIReader from LoadImage (#1796)
bhashemian Mar 18, 2021
7d25743
1804 add pretrain options (#1805)
yiheng-wang-nv Mar 19, 2021
70388fa
1809 add std shift intensity transform (#1810)
yiheng-wang-nv Mar 19, 2021
3e313d2
PadListDataCollate transform (#1813)
rijobro Mar 19, 2021
fdf26fb
Jupyter Utilities (#1797)
ericspod Mar 19, 2021
a2aeb40
Batch inverse (#1795)
rijobro Mar 20, 2021
b6f213e
1804 add pretrain for densenet senet by using subclass (#1812)
yiheng-wang-nv Mar 22, 2021
5151b15
remove .value from InverseKeys enum (#1817)
rijobro Mar 22, 2021
06e1e99
cron tutorial notebooks (#1783)
rijobro Mar 22, 2021
a8f83e1
refactor CommonKeys (#1825)
rijobro Mar 22, 2021
db2f47d
[1823] allow None for switch endianness (#1824)
rijobro Mar 22, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ __pycache__/
docs/

.coverage
.coverage.*
.coverage/
coverage.xml
.readthedocs.yml
*.md
*.toml
Expand Down
4 changes: 2 additions & 2 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ A few sentences describing the changes proposed in this pull request.
- [x] Non-breaking change (fix or new feature that would not break existing functionality).
- [ ] Breaking change (fix or new feature that would cause existing functionality to change).
- [ ] New tests added to cover the changes.
- [ ] Integration tests passed locally by running `./runtests.sh --codeformat --coverage`.
- [ ] Quick tests passed locally by running `./runtests.sh --quick`.
- [ ] Integration tests passed locally by running `./runtests.sh -f -u --net --coverage`.
- [ ] Quick tests passed locally by running `./runtests.sh --quick --unittests`.
- [ ] In-line docstrings updated.
- [ ] Documentation updated, tested `make html` command in the `docs/` folder.
81 changes: 66 additions & 15 deletions .github/workflows/cron.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
runs-on: [self-hosted, linux, x64, common]
strategy:
matrix:
pytorch-version: [1.5.0, 1.5.1, 1.6.0, latest]
pytorch-version: [1.5.1, 1.6.0, 1.7.1, latest]
steps:
- uses: actions/checkout@v2
- name: Install the dependencies
Expand All @@ -23,15 +23,12 @@ jobs:
python -m pip uninstall -y torch torchvision
if [ ${{ matrix.pytorch-version }} == "latest" ]; then
python -m pip install torch torchvision
elif [ ${{ matrix.pytorch-version }} == "1.5.0" ]; then
python -m pip install torch==1.5.0
python -m pip install torchvision==0.6.0
elif [ ${{ matrix.pytorch-version }} == "1.5.1" ]; then
python -m pip install torch==1.5.1
python -m pip install torchvision==0.6.1
python -m pip install torch==1.5.1 torchvision==0.6.1
elif [ ${{ matrix.pytorch-version }} == "1.6.0" ]; then
python -m pip install torch==1.6.0
python -m pip install torchvision==0.7.0
python -m pip install torch==1.6.0 torchvision==0.7.0
elif [ ${{ matrix.pytorch-version }} == "1.7.1" ]; then
python -m pip install torch==1.7.1 torchvision==0.8.2
fi
python -m pip install -r requirements-dev.txt
python -m pip list
Expand All @@ -43,9 +40,16 @@ jobs:
nvidia-smi
export CUDA_VISIBLE_DEVICES=$(python -m tests.utils)
echo $CUDA_VISIBLE_DEVICES
stop_time=$((LAUNCH_DELAY + $(date +%s)))
while [ $(date +%s) -lt $stop_time ]; do
python -c 'import torch; torch.rand(5, 3, device=torch.device("cuda:0"))';
done
python -c "import torch; print(torch.__version__); print('{} of GPUs available'.format(torch.cuda.device_count()))"
python -c 'import torch; print(torch.rand(5,3, device=torch.device("cuda:0")))'
BUILD_MONAI=1 ./runtests.sh --coverage
python -c 'import torch; print(torch.rand(5, 3, device=torch.device("cuda:0")))'
BUILD_MONAI=1 ./runtests.sh --coverage --unittests # unit tests with coverage report
export CUDA_VISIBLE_DEVICES=$(python -m tests.utils)
echo $CUDA_VISIBLE_DEVICES
BUILD_MONAI=1 ./runtests.sh --coverage --net # integration tests with coverage report
coverage xml
- name: Upload coverage
uses: codecov/codecov-action@v1
Expand All @@ -56,12 +60,16 @@ jobs:
cron-pt-image:
if: github.repository == 'Project-MONAI/MONAI'
container:
image: nvcr.io/nvidia/pytorch:20.12-py3 # testing with the latest pytorch base image
image: nvcr.io/nvidia/pytorch:21.02-py3 # testing with the latest pytorch base image
options: "--gpus all"
runs-on: [self-hosted, linux, x64, common]
steps:
- uses: actions/checkout@v2
- name: Install the dependencies
- name: Install APT dependencies
run: |
apt-get update
DEBIAN_FRONTEND="noninteractive" apt-get install -y libopenslide0
- name: Install Python dependencies
run: |
which python
python -m pip install --upgrade pip wheel
Expand All @@ -75,9 +83,16 @@ jobs:
nvidia-smi
export CUDA_VISIBLE_DEVICES=$(python -m tests.utils)
echo $CUDA_VISIBLE_DEVICES
stop_time=$((LAUNCH_DELAY + $(date +%s)))
while [ $(date +%s) -lt $stop_time ]; do
python -c 'import torch; torch.rand(5, 3, device=torch.device("cuda:0"))';
done
python -c "import torch; print(torch.__version__); print('{} of GPUs available'.format(torch.cuda.device_count()))"
python -c 'import torch; print(torch.rand(5,3, device=torch.device("cuda:0")))'
BUILD_MONAI=1 ./runtests.sh --coverage
python -c 'import torch; print(torch.rand(5, 3, device=torch.device("cuda:0")))'
BUILD_MONAI=1 ./runtests.sh --coverage --unittests # unit tests with coverage report
export CUDA_VISIBLE_DEVICES=$(python -m tests.utils)
echo $CUDA_VISIBLE_DEVICES
BUILD_MONAI=1 ./runtests.sh --coverage --net # integration tests with coverage report
coverage xml
- name: Upload coverage
uses: codecov/codecov-action@v1
Expand All @@ -103,10 +118,46 @@ jobs:
python -c "import torch; print(torch.__version__); print('{} of GPUs available'.format(torch.cuda.device_count()))"
python -c 'import torch; print(torch.rand(5,3, device=torch.device("cuda:0")))'
ngc --version
BUILD_MONAI=1 ./runtests.sh --coverage --pytype
BUILD_MONAI=1 ./runtests.sh --coverage --pytype --unittests # unit tests with pytype checks, coverage report
export CUDA_VISIBLE_DEVICES=$(python -m tests.utils)
echo $CUDA_VISIBLE_DEVICES
BUILD_MONAI=1 ./runtests.sh --coverage --net # integration tests with coverage report
coverage xml
- name: Upload coverage
uses: codecov/codecov-action@v1
with:
fail_ci_if_error: false
file: ./coverage.xml

cron-tutorial-notebooks:
if: github.repository == 'Project-MONAI/MONAI'
needs: cron-gpu # so that monai itself is verified first
container:
image: nvcr.io/nvidia/pytorch:21.02-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
- name: Install MONAI
id: monai-install
run: |
which python
python -m pip install --upgrade pip wheel
python -m pip install -r requirements-dev.txt
BUILD_MONAI=0 python setup.py develop # install monai
nvidia-smi
export CUDA_VISIBLE_DEVICES=$(python -m tests.utils)
echo $CUDA_VISIBLE_DEVICES
echo "::set-output name=devices::$CUDA_VISIBLE_DEVICES"
- 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
cd tutorials
python -m pip install -r requirements.txt
- name: Run tutorial notebooks
run: |
export CUDA_VISIBLE_DEVICES=${{ steps.monai-install.outputs.devices }}
echo $CUDA_VISIBLE_DEVICES
cd /opt/tutorials
$(pwd)/runner.sh
8 changes: 4 additions & 4 deletions .github/workflows/integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
jobs:
integration-py3:
container:
image: nvcr.io/nvidia/pytorch:20.03-py3 # CUDA 10.2
image: nvcr.io/nvidia/pytorch:20.12-py3 # CUDA 11.1, default for PT 1.8.0
options: --gpus all
runs-on: [self-hosted, linux, x64, common]
steps:
Expand All @@ -28,13 +28,13 @@ jobs:
path: |
~/.cache/pip
~/.cache/torch
key: docker-20-03-py3-pip-${{ steps.pip-cache.outputs.datew }}
key: docker-py3-pip-${{ steps.pip-cache.outputs.datew }}
- name: Install the dependencies
run: |
which python
python -m pip install --upgrade pip wheel
python -m pip uninstall -y torch torchvision
python -m pip install torch==1.7.1 torchvision==0.8.2
python -m pip install torch==1.8.0 torchvision==0.9.0
python -m pip install -r requirements-dev.txt
- name: Run integration tests
run: |
Expand All @@ -44,7 +44,7 @@ jobs:
echo $CUDA_VISIBLE_DEVICES
python -c "import torch; print(torch.__version__); print('{} of GPUs available'.format(torch.cuda.device_count()))"
python -c 'import torch; print(torch.rand(5,3, device=torch.device("cuda:0")))'
BUILD_MONAI=1 ./runtests.sh --net
BUILD_MONAI=1 ./runtests.sh --unittests --net
- name: Add reaction
uses: peter-evans/create-or-update-comment@v1
with:
Expand Down
44 changes: 28 additions & 16 deletions .github/workflows/pythonapp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:

jobs:
# caching of these jobs:
# - docker-20-03-py3-pip- (shared)
# - docker-py3-pip- (shared)
# - ubuntu py37 pip-
# - os-latest-pip- (shared)
flake8-py3:
Expand Down Expand Up @@ -39,7 +39,7 @@ jobs:
# clean up temporary files
$(pwd)/runtests.sh --clean
# Git hub actions have 2 cores, so parallize pytype
$(pwd)/runtests.sh --nounittests --codeformat -j 2
$(pwd)/runtests.sh --codeformat -j 2

quick-py3: # full dependencies installed
runs-on: ${{ matrix.os }}
Expand Down Expand Up @@ -80,13 +80,16 @@ jobs:
- if: runner.os == 'windows'
name: Install torch cpu from pytorch.org (Windows only)
run: |
python -m pip install torch==1.7.1+cpu torchvision==0.8.2+cpu -f https://download.pytorch.org/whl/torch_stable.html
python -m pip install torch==1.8.0+cpu torchvision==0.9.0+cpu -f https://download.pytorch.org/whl/torch_stable.html
# min. requirements for windows instances
python -c "f=open('requirements-dev.txt', 'r'); txt=f.readlines(); f.close(); print(txt); f=open('requirements-dev.txt', 'w'); f.writelines(txt[1:12]); f.close()"
- if: runner.os == 'macos'
name: Remove cucim installation (Mac only)
run: |
python -c "f=open('requirements-dev.txt', 'r'); txt=f.readlines(); f.close(); print(txt); f=open('requirements-dev.txt', 'w'); f.writelines([t for t in txt if not t.startswith('cucim')]); f.close()"
- name: Install the dependencies
run: |
python -m pip install torch==1.7.1
python -m pip install torchvision==0.8.2
python -m pip install torch==1.8.0 torchvision==0.9.0
cat "requirements-dev.txt"
python -m pip install -r requirements-dev.txt
python -m pip list
Expand Down Expand Up @@ -134,11 +137,11 @@ jobs:
- if: runner.os == 'windows'
name: Install torch cpu from pytorch.org (Windows only)
run: |
python -m pip install torch==1.7.1+cpu -f https://download.pytorch.org/whl/torch_stable.html
python -m pip install torch==1.8.0+cpu -f https://download.pytorch.org/whl/torch_stable.html
- name: Install the dependencies
run: |
# min. requirements
python -m pip install torch==1.7.1
python -m pip install torch==1.8.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 @@ -156,15 +159,13 @@ jobs:
strategy:
matrix:
environment:
- "PT15+CUDA101"
- "PT16+CUDA102"
- "PT16+CUDA110"
- "PT17+CUDA102"
- "PT17+CUDA110"
- "PT18+CUDA102"
- "PT18+CUDA112"
include:
- environment: PT15+CUDA101
pytorch: "torch==1.5.0+cu101 torchvision==0.6.0+cu101 -f https://download.pytorch.org/whl/torch_stable.html"
base: "nvcr.io/nvidia/cuda:10.1-devel-ubuntu18.04"
- environment: PT16+CUDA102
pytorch: "torch==1.6.0 torchvision==0.7.0"
base: "nvcr.io/nvidia/cuda:10.2-devel-ubuntu18.04"
Expand All @@ -179,6 +180,13 @@ jobs:
# we explicitly set pytorch to -h to avoid pip install error
pytorch: "-h"
base: "nvcr.io/nvidia/pytorch:20.09-py3"
- environment: PT18+CUDA102
pytorch: "torch==1.8.0 torchvision==0.9.0"
base: "nvcr.io/nvidia/cuda:10.2-devel-ubuntu18.04"
- environment: PT18+CUDA112
# we explicitly set pytorch to -h to avoid pip install error
pytorch: "-h"
base: "nvcr.io/nvidia/pytorch:21.02-py3"
container:
image: ${{ matrix.base }}
options: --gpus all
Expand All @@ -187,7 +195,10 @@ jobs:
- uses: actions/checkout@v2
- name: apt install
run: |
if [ ${{ matrix.environment }} != "PT16+CUDA110" ]; then \
if [ ${{ matrix.environment }} = "PT16+CUDA102" ] || \
[ ${{ matrix.environment }} = "PT17+CUDA102" ] || \
[ ${{ matrix.environment }} = "PT18+CUDA102" ]
then
PYVER=3.6 PYSFX=3 DISTUTILS=python3-distutils && \
apt-get update && apt-get install -y --no-install-recommends \
curl \
Expand Down Expand Up @@ -217,7 +228,8 @@ jobs:
ln -s /usr/bin/python$PYVER /usr/bin/python`echo $PYVER | cut -c1-1` &&
curl -O https://bootstrap.pypa.io/get-pip.py && \
python get-pip.py && \
rm get-pip.py ; fi
rm get-pip.py;
fi
- name: Install dependencies
run: |
which python
Expand All @@ -231,10 +243,10 @@ jobs:
export CUDA_VISIBLE_DEVICES=$(coverage run -m tests.utils)
echo $CUDA_VISIBLE_DEVICES
python -c "import torch; print(torch.__version__); print('{} of GPUs available'.format(torch.cuda.device_count()))"
python -c 'import torch; print(torch.rand(5,3, device=torch.device("cuda:0")))'
python -c 'import torch; print(torch.rand(5, 3, device=torch.device("cuda:0")))'
python -c "import monai; monai.config.print_config()"
BUILD_MONAI=1 ./runtests.sh --quick
if [ ${{ matrix.environment }} == "PT16+CUDA110" ]; then
BUILD_MONAI=1 ./runtests.sh --quick --unittests
if [ ${{ matrix.environment }} == "PT18+CUDA112" ]; then
# test the clang-format tool downloading once
coverage run -m tests.clang_format_utils
fi
Expand Down
22 changes: 16 additions & 6 deletions .github/workflows/setupapp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:

jobs:
# caching of these jobs:
# - docker-20-03-py3-pip- (shared)
# - docker-py3-pip- (shared)
# - ubuntu py36 37 38-pip-
# - os-latest-pip (shared)
coverage-py3:
Expand All @@ -30,7 +30,7 @@ jobs:
path: |
~/.cache/pip
~/.cache/torch
key: docker-20-03-py3-pip-${{ steps.pip-cache.outputs.datew }}
key: docker-py3-pip-${{ steps.pip-cache.outputs.datew }}
- name: Install the dependencies
run: |
which python
Expand All @@ -41,17 +41,27 @@ jobs:
- name: Run unit tests report coverage
run: |
python -m pip list
export LAUNCH_DELAY=$[ $RANDOM % 16 * 60 ]
echo "Sleep $LAUNCH_DELAY"
sleep $LAUNCH_DELAY
nvidia-smi
export CUDA_VISIBLE_DEVICES=$(python -m tests.utils)
echo $CUDA_VISIBLE_DEVICES
stop_time=$((LAUNCH_DELAY + $(date +%s)))
while [ $(date +%s) -lt $stop_time ]; do
python -c 'import torch; torch.rand(5, 3, device=torch.device("cuda:0"))';
done
python -c "import torch; print(torch.__version__); print('{} of GPUs available'.format(torch.cuda.device_count()))"
python -c 'import torch; print(torch.rand(5,3, device=torch.device("cuda:0")))'
BUILD_MONAI=1 ./runtests.sh --coverage
python -c 'import torch; print(torch.rand(5, 3, device=torch.device("cuda:0")))'
BUILD_MONAI=1 ./runtests.sh --coverage --unittests # unit tests with coverage report
export CUDA_VISIBLE_DEVICES=$(python -m tests.utils)
echo $CUDA_VISIBLE_DEVICES
BUILD_MONAI=1 ./runtests.sh --coverage --net # integration tests with coverage report
coverage xml
- name: Upload coverage
uses: codecov/codecov-action@v1
with:
fail_ci_if_error: true
fail_ci_if_error: false
file: ./coverage.xml

test-py3x:
Expand Down Expand Up @@ -88,7 +98,7 @@ jobs:
run: |
python -m pip list
python -c 'import torch; print(torch.__version__); print(torch.rand(5,3))'
BUILD_MONAI=1 ./runtests.sh --quick
BUILD_MONAI=1 ./runtests.sh --quick --unittests
coverage xml
- name: Upload coverage
uses: codecov/codecov-action@v1
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ htmlcov/
.tox/
.coverage
.coverage.*
.coverage/
.cache
nosetests.xml
coverage.xml
Expand Down Expand Up @@ -124,6 +125,7 @@ temp/
# temporary testing data MedNIST
tests/testing_data/MedNIST*
tests/testing_data/*Hippocampus*
tests/testing_data/CMU-1.tiff

# clang format tool
.clang-format-bin/
Expand Down
Loading