Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 6 additions & 7 deletions backends/arm/test/ops/test_depthwise_conv.py
Original file line number Diff line number Diff line change
Expand Up @@ -156,11 +156,14 @@
("two_dw_conv2d", two_dw_conv2d),
]

testsuite_conv2d_u85_xfails = [
testsuite_conv2d_u85 = [
("2x2_1x6x4x4_gp6_st1", dw_conv2d_2x2_1x6x4x4_gp6_st1),
("3x3_1x3x256x256_gp3_st1", dw_conv2d_3x3_1x3x256x256_gp3_st1),
("3x3_1x4x256x256_gp4_st1", dw_conv2d_3x3_1x4x256x256_gp4_st1),
("3x3_1x4x256x256_gp4_nobias", dw_conv2d_3x3_1x4x256x256_gp4_nobias),
]

testsuite_conv2d_u85_xfails = [
("3x3_2x8x198x198_gp8_st3", dw_conv2d_3x3_2x8x198x198_gp8_st3),
("two_dw_conv2d", two_dw_conv2d),
]
Expand Down Expand Up @@ -284,7 +287,7 @@ def test_dw_conv1d_u55_BI(
model.get_inputs(),
)

@parameterized.expand(testsuite_conv1d[2:])
@parameterized.expand(testsuite_conv1d + testsuite_conv2d_u85)
def test_dw_conv_u85_BI(
self, test_name: str, model: torch.nn.Module, set_quantize_io: bool = False
):
Expand All @@ -296,12 +299,8 @@ def test_dw_conv_u85_BI(
model.get_inputs(),
)

testsuite_conv2d_u85_xfails.remove(
("3x3_1x3x256x256_gp3_st1", dw_conv2d_3x3_1x3x256x256_gp3_st1)
) # Works

# All test cases except 3x3_1x3x256x256_gp3_st1 have numerical issues on FVP. MLETORCH-520
@parameterized.expand(testsuite_conv2d_u85_xfails + testsuite_conv1d[:2])
@parameterized.expand(testsuite_conv2d_u85_xfails)
@conftest.expectedFailureOnFVP
def test_dw_conv_u85_BI_xfails(
self, test_name: str, model: torch.nn.Module, set_quantize_io: bool = False
Expand Down
30 changes: 28 additions & 2 deletions backends/arm/test/ops/test_div.py
Original file line number Diff line number Diff line change
Expand Up @@ -183,8 +183,21 @@ def test_div_tosa_BI(
test_data = (input_, other_)
self._test_div_tosa_BI_pipeline(self.Div(), test_data)

@parameterized.expand(test_data_suite[:2])
def test_div_u55_BI(
self,
test_name: str,
input_: Union[torch.Tensor, torch.types.Number],
other_: Union[torch.Tensor, torch.types.Number],
rounding_mode: Optional[str] = None,
):
test_data = (input_, other_)
self._test_div_ethos_BI_pipeline(
self.Div(), common.get_u55_compile_spec(), test_data
)

# Numerical issues on FVP likely due to mul op, MLETORCH-521
@parameterized.expand(test_data_suite)
@parameterized.expand(test_data_suite[2:])
@conftest.expectedFailureOnFVP
def test_div_u55_BI_xfails(
self,
Expand All @@ -198,8 +211,21 @@ def test_div_u55_BI_xfails(
self.Div(), common.get_u55_compile_spec(), test_data
)

@parameterized.expand(test_data_suite[:2])
def test_div_u85_BI(
self,
test_name: str,
input_: Union[torch.Tensor, torch.types.Number],
other_: Union[torch.Tensor, torch.types.Number],
rounding_mode: Optional[str] = None,
):
test_data = (input_, other_)
self._test_div_ethos_BI_pipeline(
self.Div(), common.get_u85_compile_spec(), test_data
)

# Numerical issues on FVP likely due to mul op, MLETORCH-521
@parameterized.expand(test_data_suite)
@parameterized.expand(test_data_suite[2:])
@conftest.expectedFailureOnFVP
def test_div_u85_BI_xfails(
self,
Expand Down
7 changes: 1 addition & 6 deletions backends/arm/test/ops/test_mul.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,9 +152,7 @@ def test_mul_tosa_BI(
test_data = (input_, other_)
self._test_mul_tosa_BI_pipeline(self.Mul(), test_data)

# Numerical issues on FVP, MLETORCH-521
@parameterized.expand(test_data_sute)
@conftest.expectedFailureOnFVP
def test_mul_u55_BI(
self,
test_name: str,
Expand All @@ -166,10 +164,7 @@ def test_mul_u55_BI(
common.get_u55_compile_spec(), self.Mul(), test_data
)

# Numerical issues on FVP, MLETORCH-521
# test_data_sute[0] works on U85
@parameterized.expand(test_data_sute[1:])
@conftest.expectedFailureOnFVP
@parameterized.expand(test_data_sute)
def test_mul_u85_BI(
self,
test_name: str,
Expand Down
Loading