Skip to content
Merged
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
20 changes: 12 additions & 8 deletions tests/python/relay/test_auto_scheduler_tuning.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
import tempfile

import numpy as np
import pytest

from tvm import auto_scheduler, relay
from tvm.contrib import graph_executor
Expand All @@ -26,7 +27,16 @@
from test_auto_scheduler_task_extraction import get_network


def tune_network(network, target):
network = tvm.testing.parameter(
"mlp",
pytest.param("winograd-test", marks=pytest.mark.xfail(reason="Flaky unit test")),
)


@tvm.testing.requires_cuda
def test_tuning_cuda(network):
target = "cuda"

# Extract tasks
mod, params = get_network(network)
target = tvm.target.Target(target)
Expand Down Expand Up @@ -104,11 +114,5 @@ def get_output(data, lib):
tvm.testing.assert_allclose(actual_output2, expected_output, rtol=1e-4, atol=1e-4)


@tvm.testing.requires_cuda
def test_tuning_cuda():
tune_network("mlp", "cuda")
tune_network("winograd-test", "cuda")


if __name__ == "__main__":
test_tuning_cuda()
tvm.testing.main()