From d4008907ea5be5bb39ba8133b7b898b1e093a3b7 Mon Sep 17 00:00:00 2001 From: Uma Devi Selvaraj Date: Wed, 6 Nov 2024 14:35:35 +0530 Subject: [PATCH] #6991 WHB0 tests file updates * #6991: Update test skips * #6991: Rename to update the position of the test files --------- Co-authored-by: umadevimcw --- tests/ttnn/unit_tests/operations/test_reduction.py | 5 ----- .../operations/{test_mean.py => test_reduction_mean.py} | 5 +---- .../operations/{test_min.py => test_reduction_min.py} | 6 +----- tests/ttnn/unit_tests/operations/test_sum.py | 6 +----- 4 files changed, 3 insertions(+), 19 deletions(-) rename tests/ttnn/unit_tests/operations/{test_mean.py => test_reduction_mean.py} (81%) rename tests/ttnn/unit_tests/operations/{test_min.py => test_reduction_min.py} (88%) diff --git a/tests/ttnn/unit_tests/operations/test_reduction.py b/tests/ttnn/unit_tests/operations/test_reduction.py index f410dd508f9..6769fea9414 100644 --- a/tests/ttnn/unit_tests/operations/test_reduction.py +++ b/tests/ttnn/unit_tests/operations/test_reduction.py @@ -8,7 +8,6 @@ import ttnn from tests.ttnn.utils_for_testing import assert_with_pcc -from models.utility_functions import torch_random, is_wormhole_b0 @pytest.mark.parametrize("batch_size", [1, 16]) @@ -17,8 +16,6 @@ @pytest.mark.parametrize("dim", [-1, -2]) def test_std(device, batch_size, h, w, dim): torch.manual_seed(0) - if is_wormhole_b0() and dim == -2: - pytest.skip("Issue #6991: PCC mismatch for dim=-2") torch_input_tensor = torch.randn((batch_size, h, w), dtype=torch.bfloat16) torch_output_tensor = torch.std(torch_input_tensor, dim=dim, keepdim=True) @@ -39,8 +36,6 @@ def test_std(device, batch_size, h, w, dim): @pytest.mark.parametrize("dim", [-1, -2]) def test_var(device, batch_size, h, w, dim): torch.manual_seed(0) - if is_wormhole_b0() and dim == -2: - pytest.skip("Issue #6991: PCC mismatch for dim=-2") torch_input_tensor = torch.randn((batch_size, h, w), dtype=torch.bfloat16) torch_output_tensor = torch.var(torch_input_tensor, dim=dim, keepdim=True) diff --git a/tests/ttnn/unit_tests/operations/test_mean.py b/tests/ttnn/unit_tests/operations/test_reduction_mean.py similarity index 81% rename from tests/ttnn/unit_tests/operations/test_mean.py rename to tests/ttnn/unit_tests/operations/test_reduction_mean.py index c4c8a959ad7..79e2a0aa581 100644 --- a/tests/ttnn/unit_tests/operations/test_mean.py +++ b/tests/ttnn/unit_tests/operations/test_reduction_mean.py @@ -8,7 +8,7 @@ import ttnn from tests.ttnn.utils_for_testing import assert_with_pcc -from models.utility_functions import torch_random, is_wormhole_b0, is_wormhole_b0 +from models.utility_functions import torch_random @pytest.mark.parametrize("batch_size", [1, 16, 1, 16]) @@ -18,9 +18,6 @@ def test_mean(device, batch_size, h, w, dim): torch.manual_seed(0) - if is_wormhole_b0() and dim == -2: - pytest.skip("Issue #6991: Wormhole B0: mean operation fails for dim=-2") - torch_input_tensor = torch_random((batch_size, h, w), -1, 1, dtype=torch.bfloat16) torch_output_tensor = torch.mean(torch_input_tensor, dim=dim, keepdim=True, dtype=torch.bfloat16) diff --git a/tests/ttnn/unit_tests/operations/test_min.py b/tests/ttnn/unit_tests/operations/test_reduction_min.py similarity index 88% rename from tests/ttnn/unit_tests/operations/test_min.py rename to tests/ttnn/unit_tests/operations/test_reduction_min.py index 16601f146ad..c520c87fb7c 100644 --- a/tests/ttnn/unit_tests/operations/test_min.py +++ b/tests/ttnn/unit_tests/operations/test_reduction_min.py @@ -8,7 +8,7 @@ import ttnn from tests.ttnn.utils_for_testing import assert_with_pcc -from models.utility_functions import torch_random, is_wormhole_b0 +from models.utility_functions import torch_random @pytest.mark.parametrize("batch_size", [1, 16, 1, 16]) @@ -16,8 +16,6 @@ @pytest.mark.parametrize("w", [32, 64, 31, 63]) @pytest.mark.parametrize("dim", [-1, -2]) def test_min(device, batch_size, h, w, dim): - if is_wormhole_b0() and dim == -2: - pytest.skip("Issue #6991: PCC mismatch for dim=-2") torch.manual_seed(0) torch_input_tensor = torch_random((batch_size, h, w), -100, 100, dtype=torch.bfloat16) @@ -37,8 +35,6 @@ def test_min(device, batch_size, h, w, dim): @pytest.mark.parametrize("h", [32, 64, 41, 37]) @pytest.mark.parametrize("w", [32, 64, 31, 63]) def test_min_global(device, batch_size, h, w): - if is_wormhole_b0(): - pytest.skip("Issue #6991: PCC mismatch") torch.manual_seed(0) torch_input_tensor = torch_random((batch_size, h, w), -100, 100, dtype=torch.bfloat16) diff --git a/tests/ttnn/unit_tests/operations/test_sum.py b/tests/ttnn/unit_tests/operations/test_sum.py index c43a0aa2a0e..ccbf7c7859d 100644 --- a/tests/ttnn/unit_tests/operations/test_sum.py +++ b/tests/ttnn/unit_tests/operations/test_sum.py @@ -8,7 +8,7 @@ import ttnn from tests.ttnn.utils_for_testing import assert_with_pcc -from models.utility_functions import torch_random, is_wormhole_b0 +from models.utility_functions import torch_random @pytest.mark.parametrize("batch_size", [1, 16, 1, 16]) @@ -17,8 +17,6 @@ @pytest.mark.parametrize("dim", [-1, -2, (2, 1)]) def test_sum(device, batch_size, h, w, dim): torch.manual_seed(0) - if is_wormhole_b0(): - pytest.skip("Issue #6991: PCC mismatch") torch_input_tensor = torch_random((batch_size, h, w), -100, 100, dtype=torch.bfloat16) torch_output_tensor = torch.sum(torch_input_tensor, dim=dim, keepdim=True) @@ -38,8 +36,6 @@ def test_sum(device, batch_size, h, w, dim): @pytest.mark.parametrize("w", [32, 64, 31, 63]) def test_sum_global(device, batch_size, h, w): torch.manual_seed(0) - if is_wormhole_b0(): - pytest.skip("Issue #6991: PCC mismatch") torch_input_tensor = torch_random((batch_size, h, w), -100, 100, dtype=torch.bfloat16) torch_output_tensor = torch.sum(torch_input_tensor)