已合并
Skip when device name is Ascend910B4 #30128
Skip when device name is Ascend910B4 #30128
已合并
haiyan8创建于 1月28日
共 1 个文件变更+3-0
@@ -9,8 +9,11 @@ from torch.testing._internal.common_utils import TestCase, run_tests, TEST_PRIVA
9 9 
10os.environ["PYTORCH_NPU_ALLOC_CONF"] = "expandable_segments:True"10os.environ["PYTORCH_NPU_ALLOC_CONF"] = "expandable_segments:True"
11 11 
12+device_name = torch_npu.npu.get_device_name(0)
13+ 
12 14 
13class Test_expandable_segments(TestCase):15class Test_expandable_segments(TestCase):
16+ @unittest.skipIf(device_name == "Ascend910B4", "Skip when device name is Ascend910B4")
14 def test_empty_virt_addr_cache(self):17 def test_empty_virt_addr_cache(self):
15 gc.collect()18 gc.collect()
16 torch_npu.npu.empty_cache()19 torch_npu.npu.empty_cache()