MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / infer

Function infer

imperative/python/test/unit/utils/test_profiler.py:39–42  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

37 profile_path = os.path.join(profile_prefix, "{}.{}".format(os.getpid(), format))
38
39 def infer():
40 with scope("my_scope"):
41 oup = Simple()(tensor([1.23], dtype="float32"))
42 return oup
43
44 if trace_mode:
45 infer = trace(symbolic=trace_mode)(infer)

Callers 6

test_profilerFunction · 0.70
workerFunction · 0.70
do_inferMethod · 0.50
infer_shapeMethod · 0.50
infer_valueMethod · 0.50

Calls 2

scopeFunction · 0.90
SimpleClass · 0.70

Tested by

no test coverage detected