MCPcopy Create free account
hub / github.com/apache/tvm / gen_ground_truth

Function gen_ground_truth

tests/python/relax/test_transform_codegen_pass.py:78–89  ·  view source on GitHub ↗
(mod, target, dev, inputs)

Source from the content-addressed store, hash-verified

76
77
78def gen_ground_truth(mod, target, dev, inputs):
79 # Lower and run tuning
80 # Since there is no default schedule for GPU in MS yet, this is necessary
81 with target:
82 seq = tvm.transform.Sequential(
83 [relax.transform.LegalizeOps(), s_tir.transform.DefaultGPUSchedule()]
84 )
85 new_mod = seq(mod)
86 relax.analysis.well_formed(new_mod)
87 exec = tvm.compile(new_mod, target, params={})
88 vm = relax.VirtualMachine(exec, dev)
89 return vm["main"](*inputs)
90
91
92@tvm.script.ir_module

Callers 1

setup_testFunction · 0.85

Calls 1

compileMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…