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

Method __copy__

imperative/python/megengine/traced_module/expr.py:298–302  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

296 cls.__total_id = id
297
298 def __copy__(self):
299 cls = self.__class__
300 result = cls.__new__(cls)
301 result.__dict__.update(self.__dict__)
302 return result
303
304 def __deepcopy__(self, memo):
305 cls = self.__class__

Callers

nothing calls this directly

Calls 2

__new__Method · 0.45
updateMethod · 0.45

Tested by

no test coverage detected