Skip to content

Commit 600621d

Browse files
authored
Ignore none json/yaml config for bundleAgo (#6235)
Fixes #6234 . ### Ignore files that does not end with json or yaml during autorunner cmd creation. ### Types of changes <!--- Put an `x` in all the boxes that apply, and remove the not applicable items --> - [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 -f -u --net --coverage`. - [ ] Quick tests passed locally by running `./runtests.sh --quick --unittests --disttests`. - [ ] In-line docstrings updated. - [ ] Documentation updated, tested `make html` command in the `docs/` folder. --------- Signed-off-by: heyufan1995 <heyufan1995@gmail.com>
1 parent c0aace5 commit 600621d

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

.github/workflows/setupapp.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ jobs:
7676
runs-on: ubuntu-latest
7777
strategy:
7878
matrix:
79-
python-version: ['3.9', '3.10']
79+
python-version: ['3.8', '3.9', '3.10']
8080
steps:
8181
- uses: actions/checkout@v3
8282
with:
@@ -100,13 +100,13 @@ jobs:
100100
- name: Install the dependencies
101101
run: |
102102
python -m pip install --upgrade pip wheel
103-
python -m pip install torch==1.13.1 torchvision==0.14.1
104103
python -m pip install -r requirements-dev.txt
105104
- name: Run quick tests CPU ubuntu
106105
run: |
107106
python -m pip list
108107
python -c 'import torch; print(torch.__version__); print(torch.rand(5,3))'
109-
BUILD_MONAI=1 ./runtests.sh --build --quick --unittests --disttests
108+
BUILD_MONAI=0 ./runtests.sh --build --quick --unittests --disttests
109+
BUILD_MONAI=1 ./runtests.sh --build --quick --min
110110
coverage xml --ignore-errors
111111
- name: Upload coverage
112112
uses: codecov/codecov-action@v3

monai/apps/auto3dseg/bundle_gen.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,8 @@ def _create_cmd(self, train_params=None):
155155
if os.path.isdir(config_dir):
156156
base_cmd = ""
157157
for file in os.listdir(config_dir):
158+
if not (file.endswith("yaml") or file.endswith("json")):
159+
continue
158160
if len(base_cmd) == 0:
159161
base_cmd += f"{train_py} run --config_file="
160162
else:

0 commit comments

Comments
 (0)