diff --git a/topi/tests/python/test_topi_conv2d_nhwc_winograd.py b/topi/tests/python/test_topi_conv2d_nhwc_winograd.py index 45f0599bae4d..a7e55320d6dd 100644 --- a/topi/tests/python/test_topi_conv2d_nhwc_winograd.py +++ b/topi/tests/python/test_topi_conv2d_nhwc_winograd.py @@ -137,7 +137,8 @@ def test_conv2d_nhwc_winograd_direct(): def test_conv2d_nhwc_winograd_tensorcore(): """Test the conv2d with winograd for nhwc layout""" - print("test_winograd_tensorcore...") + if not nvcc.have_tensorcore(tvm.gpu(0).compute_version): + return verify_conv2d_nhwc(8, 64, 56, 64, 3, 1, 1, bgemm="tensorcore") verify_conv2d_nhwc(8, 128, 28, 128, 3, 1, 1, bgemm="tensorcore") verify_conv2d_nhwc(8, 256, 14, 256, 3, 1, 1, bgemm="tensorcore") @@ -145,8 +146,7 @@ def test_conv2d_nhwc_winograd_tensorcore(): verify_conv2d_nhwc(2, 64, 56, 64, 3, 1, (1, 1), add_relu=True, bgemm="tensorcore") verify_conv2d_nhwc(2, 64, 56, 64, 3, 1, "SAME", add_relu=True, bgemm="tensorcore") + if __name__ == "__main__": test_conv2d_nhwc_winograd_direct() - - if nvcc.have_tensorcore(tvm.gpu(0).compute_version): - test_conv2d_nhwc_winograd_tensorcore() + test_conv2d_nhwc_winograd_tensorcore()