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

Function ir_constant

imperative/python/megengine/xla/ir_utils.py:398–401  ·  view source on GitHub ↗
(val: Any, canonicalize_types: bool = True)

Source from the content-addressed store, hash-verified

396
397
398def ir_constant(val: Any, canonicalize_types: bool = True) -> Sequence[ir.Value]:
399 values = ir_constant_tuple(val, canonicalize_types=canonicalize_types)
400 assert len(values) == 1
401 return values[0]
402
403
404def token_type() -> Sequence[ir.Type]:

Callers

nothing calls this directly

Calls 1

ir_constant_tupleFunction · 0.85

Tested by

no test coverage detected