MCPcopy Create free account
hub / github.com/AIS-SNU/Smart-Infinity / empty_partition_cache

Method empty_partition_cache

deepspeed/runtime/engine.py:3367–3374  ·  view source on GitHub ↗

Release GPU memory consumed by offloaded model parameters.

(self)

Source from the content-addressed store, hash-verified

3365 return True
3366
3367 def empty_partition_cache(self):
3368 """
3369 Release GPU memory consumed by offloaded model parameters.
3370 """
3371 if hasattr(self.optimizer, 'empty_partition_cache'):
3372 self.optimizer.empty_partition_cache()
3373 gc.collect()
3374 get_accelerator().empty_cache()

Callers

nothing calls this directly

Calls 2

get_acceleratorFunction · 0.90
empty_cacheMethod · 0.45

Tested by

no test coverage detected