MCPcopy Create free account
hub / github.com/deepspeedai/DeepSpeed / __del__

Method __del__

deepspeed/runtime/engine.py:767–772  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

765 setattr(model, "ds_autotp_parsed", True)
766
767 def __del__(self):
768 try:
769 self.destroy()
770 except Exception as exc:
771 # Avoid destructor-time exceptions for partially initialized engines.
772 logger.debug("DeepSpeedEngine.__del__ cleanup skipped: %s", exc, exc_info=True)
773
774 def destroy(self):
775 optimizer = getattr(self, "optimizer", None)

Callers

nothing calls this directly

Calls 1

destroyMethod · 0.95

Tested by

no test coverage detected