Skip to content

Commit fb9901e

Browse files
NicolasHugfacebook-github-bot
authored andcommitted
[fbsync] Skip r2plus1d_18 test on linux GPU Circle CI machines (#3768)
Reviewed By: datumbox Differential Revision: D28473320 fbshipit-source-id: 8ecc3772e63f79343cce18e68ab5516f7e841710
1 parent 3c41c9c commit fb9901e

File tree

4 files changed

+8
-3
lines changed

4 files changed

+8
-3
lines changed

.circleci/config.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -648,7 +648,7 @@ jobs:
648648
command: docker run -t --gpus all -v $PWD:$PWD -w $PWD -e UPLOAD_CHANNEL -e CU_VERSION "${image_name}" .circleci/unittest/linux/scripts/install.sh
649649
- run:
650650
name: Run tests
651-
command: docker run -t --gpus all -v $PWD:$PWD -w $PWD "${image_name}" .circleci/unittest/linux/scripts/run_test.sh
651+
command: docker run -e CIRCLECI -t --gpus all -v $PWD:$PWD -w $PWD "${image_name}" .circleci/unittest/linux/scripts/run_test.sh
652652
- run:
653653
name: Post Process
654654
command: docker run -t --gpus all -v $PWD:$PWD -w $PWD "${image_name}" .circleci/unittest/linux/scripts/post_process.sh

.circleci/config.yml.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -648,7 +648,7 @@ jobs:
648648
command: docker run -t --gpus all -v $PWD:$PWD -w $PWD -e UPLOAD_CHANNEL -e CU_VERSION "${image_name}" .circleci/unittest/linux/scripts/install.sh
649649
- run:
650650
name: Run tests
651-
command: docker run -t --gpus all -v $PWD:$PWD -w $PWD "${image_name}" .circleci/unittest/linux/scripts/run_test.sh
651+
command: docker run -e CIRCLECI -t --gpus all -v $PWD:$PWD -w $PWD "${image_name}" .circleci/unittest/linux/scripts/run_test.sh
652652
- run:
653653
name: Post Process
654654
command: docker run -t --gpus all -v $PWD:$PWD -w $PWD "${image_name}" .circleci/unittest/linux/scripts/post_process.sh

test/common_utils.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
IS_PY39 = sys.version_info.major == 3 and sys.version_info.minor == 9
2424
PY39_SEGFAULT_SKIP_MSG = "Segmentation fault with Python 3.9, see https://github.com/pytorch/vision/issues/3367"
2525
PY39_SKIP = unittest.skipIf(IS_PY39, PY39_SEGFAULT_SKIP_MSG)
26+
IN_CIRCLE_CI = os.getenv("CIRCLECI", False) == 'true'
2627

2728

2829
@contextlib.contextmanager

test/test_models.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
from common_utils import TestCase, map_nested_tensor_object, freeze_rng_state, set_rng_seed
1+
import sys
2+
from common_utils import TestCase, map_nested_tensor_object, freeze_rng_state, set_rng_seed, IN_CIRCLE_CI
23
from collections import OrderedDict
34
from itertools import product
45
import functools
@@ -458,6 +459,9 @@ def test_detection_model_validation(model_name):
458459
@pytest.mark.parametrize('model_name', get_available_video_models())
459460
@pytest.mark.parametrize('dev', _devs)
460461
def test_video_model(model_name, dev):
462+
if IN_CIRCLE_CI and 'cuda' in dev.type and model_name == 'r2plus1d_18' and sys.platform == 'linux':
463+
# FIXME: Failure should fixed and test re-actived. See https://github.com/pytorch/vision/issues/3702
464+
pytest.skip('r2plus1d_18 fails on CircleCI linux GPU machines.')
461465
ModelTester()._test_video_model(model_name, dev)
462466

463467

0 commit comments

Comments
 (0)