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

Function _is_const_leaf

imperative/python/megengine/traced_module/pytree.py:193–196  ·  view source on GitHub ↗
(node)

Source from the content-addressed store, hash-verified

191
192
193def _is_const_leaf(node):
194 if isinstance(node, (RawTensor, Node, NodeMixin, Module)):
195 return False
196 return True
197
198
199def tree_flatten(

Callers 2

add_inputsMethod · 0.85
set_args_kwargsMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected