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

Function relax_call

python/tvm/relax/script/parser/parser.py:421–427  ·  view source on GitHub ↗
(self, *args)

Source from the content-addressed store, hash-verified

419@dispatch.register(token="relax", type_name="enter_token")
420def enter_token(self: Parser) -> dict[str, Any]:
421 def relax_call(self, *args) -> Expr:
422 args = [convert_to_expr(arg) if isinstance(arg, tuple) else arg for arg in args]
423
424 if all(isinstance(x, Expr) for x in args):
425 return relax.Call(self, args)
426 arg_types = [type(x) for x in args]
427 raise RuntimeError(f"Do not know how to handle GlobalVar.__call__ for types {arg_types}")
428
429 context = {"GlobalVar.__call__": GlobalVar.__call__}
430 GlobalVar.__call__ = relax_call

Callers

nothing calls this directly

Calls 2

convert_to_exprFunction · 0.90
allFunction · 0.50

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…