Skip to content

Commit

Permalink
Update ALGO_HASH to make Auto3DSeg dints support older version of PyT… (
Browse files Browse the repository at this point in the history
#6175)

Fixes 6155 .

Related PR in research contribution:
- Project-MONAI/research-contributions#204

### Description

A few sentences describing the changes proposed in this pull request.

### 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).

Signed-off-by: Mingxin Zheng <18563433+mingxin-zheng@users.noreply.github.com>
  • Loading branch information
mingxin-zheng authored Mar 21, 2023
1 parent eed660c commit f183a5e
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion monai/apps/auto3dseg/bundle_gen.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
from monai.utils import ensure_tuple

logger = get_logger(module_name=__name__)
ALGO_HASH = os.environ.get("MONAI_ALGO_HASH", "d0fa876d")
ALGO_HASH = os.environ.get("MONAI_ALGO_HASH", "d8bec42")

__all__ = ["BundleAlgo", "BundleGen"]

Expand Down
2 changes: 1 addition & 1 deletion tests/test_auto3dseg_ensemble.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@


@skip_if_quick
@SkipIfBeforePyTorchVersion((1, 13, 0))
@SkipIfBeforePyTorchVersion((1, 9, 1))
@unittest.skipIf(not has_tb, "no tensorboard summary writer")
class TestEnsembleBuilder(unittest.TestCase):
def setUp(self) -> None:
Expand Down
2 changes: 1 addition & 1 deletion tests/test_integration_autorunner.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@


@skip_if_quick
@SkipIfBeforePyTorchVersion((1, 13, 0))
@SkipIfBeforePyTorchVersion((1, 9, 1))
@unittest.skipIf(not has_tb, "no tensorboard summary writer")
class TestAutoRunner(unittest.TestCase):
def setUp(self) -> None:
Expand Down
2 changes: 1 addition & 1 deletion tests/test_integration_gpu_customization.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@


@skip_if_quick
@SkipIfBeforePyTorchVersion((1, 13, 0))
@SkipIfBeforePyTorchVersion((1, 9, 1))
@unittest.skipIf(not has_tb, "no tensorboard summary writer")
class TestEnsembleGpuCustomization(unittest.TestCase):
def setUp(self) -> None:
Expand Down
2 changes: 2 additions & 0 deletions tests/test_integration_nnunetv2_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
from tests.utils import SkipIfBeforePyTorchVersion, skip_if_downloading_fails, skip_if_no_cuda, skip_if_quick

_, has_tb = optional_import("torch.utils.tensorboard", name="SummaryWriter")
_, has_nnunet = optional_import("nnunetv2")

sim_datalist: dict[str, list[dict]] = {
"testing": [{"image": "val_001.fake.nii.gz"}, {"image": "val_002.fake.nii.gz"}],
Expand All @@ -46,6 +47,7 @@
@skip_if_quick
@SkipIfBeforePyTorchVersion((1, 13, 0))
@unittest.skipIf(not has_tb, "no tensorboard summary writer")
@unittest.skipIf(not has_nnunet, "no nnunetv2")
class TestnnUNetV2Runner(unittest.TestCase):
def setUp(self) -> None:
self.test_dir = tempfile.TemporaryDirectory()
Expand Down

0 comments on commit f183a5e

Please sign in to comment.