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

Function is_call_function

imperative/python/megengine/traced_module/expr.py:65–70  ·  view source on GitHub ↗
(expr, func: Iterable[Callable] = None)

Source from the content-addressed store, hash-verified

63
64
65def is_call_function(expr, func: Iterable[Callable] = None):
66 if func and not isinstance(func, Iterable):
67 func = (func,)
68 return isinstance(expr, CallFunction) and (
69 func is None or any(expr.func == f for f in func)
70 )
71
72
73def is_constant(expr):

Callers 7

fold_conv_mulMethod · 0.85
_forward_traveMethod · 0.85
before_visit_graphMethod · 0.85
get_const_valueMethod · 0.85
get_bn_paramsMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected