已合并
test: remove test_norm_complex_input_check #5186
21xiu创建于 6月15日
test: remove test_norm_complex_input_check #5186
已合并
共 1 个文件变更+0-9
| @@ -69,14 +69,5 @@ class TestNorm(TestCase): | |||
| 69 | exception = cm.exception | 69 | exception = cm.exception |
| 70 | self.assertTrue("Dimension out of range (expected to be in range of [-1, 0], but got 2)" in str(exception)) | 70 | self.assertTrue("Dimension out of range (expected to be in range of [-1, 0], but got 2)" in str(exception)) |
| 71 | 71 | ||
| 72 | - | ||
| 73 | - | ||
| 74 | - def test_norm_complex_input_check(self): | ||
| 75 | - x = torch.randn(32, 32, 32, dtype=torch.complex64).npu() | ||
| 76 | - with self.assertRaises(RuntimeError) as cm: | ||
| 77 | - output = torch.norm(x, 5, 2) | ||
| 78 | - exception = cm.exception | ||
| 79 | - self.assertTrue("does not support complex numbers" in str(exception)) | ||
| 80 | - | ||
| 81 | if __name__ == "__main__": | 72 | if __name__ == "__main__": |
| 82 | run_tests() | 73 | run_tests() |