MCPcopy Index your code
hub / github.com/apache/tvm / main

Method main

tests/python/contrib/test_example_npu.py:40–48  ·  view source on GitHub ↗
(
        x: R.Tensor((2, 4), "float32"),
        w: R.Tensor((4, 8), "float32"),
    )

Source from the content-addressed store, hash-verified

38
39 @R.function
40 def main(
41 x: R.Tensor((2, 4), "float32"),
42 w: R.Tensor((4, 8), "float32"),
43 ) -> R.Tensor((2, 8), "float32"):
44 with R.dataflow():
45 y = relax.op.matmul(x, w)
46 z = relax.op.nn.relu(y)
47 R.output(z)
48 return z
49
50
51@tvm.script.ir_module

Callers

nothing calls this directly

Calls 5

TensorMethod · 0.80
dataflowMethod · 0.80
outputMethod · 0.80
matmulMethod · 0.45
reluMethod · 0.45

Tested by

no test coverage detected