diff --git a/.ci/pytorch/test.sh b/.ci/pytorch/test.sh index 8fe8a0f16ffe..43014b2b10fe 100755 --- a/.ci/pytorch/test.sh +++ b/.ci/pytorch/test.sh @@ -296,7 +296,7 @@ test_python() { } -test_dynamo_shard() { +test_dynamo_wrapped_shard() { if [[ -z "$NUM_TEST_SHARDS" ]]; then echo "NUM_TEST_SHARDS must be defined to run a Python test shard" exit 1 @@ -806,7 +806,7 @@ test_without_numpy() { # Regression test for https://github.com/pytorch/pytorch/issues/66353 python -c "import sys;sys.path.insert(0, 'fake_numpy');import torch;print(torch.tensor([torch.tensor(0.), torch.tensor(1.)]))" # Regression test for https://github.com/pytorch/pytorch/issues/109387 - if [[ "${TEST_CONFIG}" == *dynamo* ]]; then + if [[ "${TEST_CONFIG}" == *dynamo_wrapped* ]]; then python -c "import sys;sys.path.insert(0, 'fake_numpy');import torch;torch.compile(lambda x:print(x))('Hello World')" fi popd @@ -1479,9 +1479,9 @@ elif [[ "${TEST_CONFIG}" == *inductor* ]]; then test_inductor_distributed fi fi -elif [[ "${TEST_CONFIG}" == *dynamo* ]]; then +elif [[ "${TEST_CONFIG}" == *dynamo_wrapped* ]]; then install_torchvision - test_dynamo_shard "${SHARD_NUMBER}" + test_dynamo_wrapped_shard "${SHARD_NUMBER}" if [[ "${SHARD_NUMBER}" == 1 ]]; then test_aten fi diff --git a/.github/workflows/pull.yml b/.github/workflows/pull.yml index 1130fb542c59..55209f76beef 100644 --- a/.github/workflows/pull.yml +++ b/.github/workflows/pull.yml @@ -195,9 +195,9 @@ jobs: { config: "default", shard: 5, num_shards: 5, runner: "${{ needs.get-label-type.outputs.label-type }}linux.4xlarge" }, { config: "crossref", shard: 1, num_shards: 2, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, { config: "crossref", shard: 2, num_shards: 2, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, - { config: "dynamo", shard: 1, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, - { config: "dynamo", shard: 2, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, - { config: "dynamo", shard: 3, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, + { config: "dynamo_wrapped", shard: 1, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, + { config: "dynamo_wrapped", shard: 2, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, + { config: "dynamo_wrapped", shard: 3, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, ]} linux-focal-py3_9-clang10-test: name: linux-focal-py3.9-clang10 @@ -228,9 +228,9 @@ jobs: { config: "default", shard: 5, num_shards: 5, runner: "${{ needs.get-label-type.outputs.label-type }}linux.4xlarge" }, { config: "crossref", shard: 1, num_shards: 2, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, { config: "crossref", shard: 2, num_shards: 2, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, - { config: "dynamo", shard: 1, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, - { config: "dynamo", shard: 2, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, - { config: "dynamo", shard: 3, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, + { config: "dynamo_wrapped", shard: 1, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, + { config: "dynamo_wrapped", shard: 2, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, + { config: "dynamo_wrapped", shard: 3, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, ]} secrets: inherit @@ -261,9 +261,9 @@ jobs: { config: "default", shard: 3, num_shards: 5, runner: "${{ needs.get-label-type.outputs.label-type }}linux.4xlarge" }, { config: "default", shard: 4, num_shards: 5, runner: "${{ needs.get-label-type.outputs.label-type }}linux.4xlarge" }, { config: "default", shard: 5, num_shards: 5, runner: "${{ needs.get-label-type.outputs.label-type }}linux.4xlarge" }, - { config: "dynamo", shard: 1, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, - { config: "dynamo", shard: 2, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, - { config: "dynamo", shard: 3, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, + { config: "dynamo_wrapped", shard: 1, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, + { config: "dynamo_wrapped", shard: 2, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, + { config: "dynamo_wrapped", shard: 3, num_shards: 3, runner: "${{ needs.get-label-type.outputs.label-type }}linux.2xlarge" }, ]} secrets: inherit @@ -601,9 +601,9 @@ jobs: { config: "default", shard: 1, num_shards: 3, runner: "linux.4xlarge" }, { config: "default", shard: 2, num_shards: 3, runner: "linux.4xlarge" }, { config: "default", shard: 3, num_shards: 3, runner: "linux.4xlarge" }, - { config: "dynamo", shard: 1, num_shards: 3, runner: "linux.2xlarge" }, - { config: "dynamo", shard: 2, num_shards: 3, runner: "linux.2xlarge" }, - { config: "dynamo", shard: 3, num_shards: 3, runner: "linux.2xlarge" }, + { config: "dynamo_wrapped", shard: 1, num_shards: 3, runner: "linux.2xlarge" }, + { config: "dynamo_wrapped", shard: 2, num_shards: 3, runner: "linux.2xlarge" }, + { config: "dynamo_wrapped", shard: 3, num_shards: 3, runner: "linux.2xlarge" }, ]} secrets: inherit diff --git a/scripts/compile_tests/download_reports.py b/scripts/compile_tests/download_reports.py index 7ad6521032c9..fa9b43e02a34 100644 --- a/scripts/compile_tests/download_reports.py +++ b/scripts/compile_tests/download_reports.py @@ -9,14 +9,14 @@ import requests CONFIGS = { "dynamo39": { - "linux-focal-py3.9-clang10 / test (dynamo, 1, 3, linux.2xlarge)", - "linux-focal-py3.9-clang10 / test (dynamo, 2, 3, linux.2xlarge)", - "linux-focal-py3.9-clang10 / test (dynamo, 3, 3, linux.2xlarge)", + "linux-focal-py3.9-clang10 / test (dynamo_wrapped, 1, 3, linux.2xlarge)", + "linux-focal-py3.9-clang10 / test (dynamo_wrapped, 2, 3, linux.2xlarge)", + "linux-focal-py3.9-clang10 / test (dynamo_wrapped, 3, 3, linux.2xlarge)", }, "dynamo311": { - "linux-focal-py3.11-clang10 / test (dynamo, 1, 3, linux.2xlarge)", - "linux-focal-py3.11-clang10 / test (dynamo, 2, 3, linux.2xlarge)", - "linux-focal-py3.11-clang10 / test (dynamo, 3, 3, linux.2xlarge)", + "linux-focal-py3.11-clang10 / test (dynamo_wrapped, 1, 3, linux.2xlarge)", + "linux-focal-py3.11-clang10 / test (dynamo_wrapped, 2, 3, linux.2xlarge)", + "linux-focal-py3.11-clang10 / test (dynamo_wrapped, 3, 3, linux.2xlarge)", }, "eager311": { "linux-focal-py3.11-clang10 / test (default, 1, 3, linux.2xlarge)", diff --git a/test/dynamo_expected_failures/TestTEFuserStatic.test_skip_grad_in_check b/test/dynamo_skips/TestOperatorsCPU.test_extremal_numerics_nll_loss_cpu similarity index 100% rename from test/dynamo_expected_failures/TestTEFuserStatic.test_skip_grad_in_check rename to test/dynamo_skips/TestOperatorsCPU.test_extremal_numerics_nll_loss_cpu diff --git a/test/dynamo_skips/TestTEFuserStatic.test_skip_grad_in_check b/test/dynamo_skips/TestTEFuserStatic.test_skip_grad_in_check new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/test/functorch/test_ops.py b/test/functorch/test_ops.py index 8de92e04c68f..cd8718292b0c 100644 --- a/test/functorch/test_ops.py +++ b/test/functorch/test_ops.py @@ -52,6 +52,7 @@ from torch.testing._internal.common_utils import ( run_tests, runOnRocm, skipIfRocm, + skipIfTorchDynamo, TEST_WITH_ASAN, TEST_WITH_ROCM, TestCase, @@ -2182,6 +2183,7 @@ class TestOperators(TestCase): cotangents = torch.randn_like(result, device=device) self._compare_jacobians_of_vjp(fn, (cotangents, input)) + @skipIfTorchDynamo("segfaults") def test_extremal_numerics_l1_loss(self, device): N, C, H, W = 3, 4, 5, 6 shapes = ((N, C), (N, C, H), (N, C, H, W)) diff --git a/torch/testing/_internal/common_utils.py b/torch/testing/_internal/common_utils.py index 764a2fc6f3c0..b34aa68f1ece 100644 --- a/torch/testing/_internal/common_utils.py +++ b/torch/testing/_internal/common_utils.py @@ -2516,6 +2516,7 @@ def check_if_enable(test: unittest.TestCase): "xpu": TEST_XPU, "asan": TEST_WITH_ASAN, "dynamo": TEST_WITH_TORCHDYNAMO, + "dynamo_wrapped": TEST_WITH_TORCHDYNAMO, "inductor": TEST_WITH_TORCHINDUCTOR, "slow": TEST_WITH_SLOW, }