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

Method __init__

accelerator/cpu_accelerator.py:167–180  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

165class CPU_Accelerator(DeepSpeedAccelerator):
166
167 def __init__(self):
168 self._name = 'cpu'
169 self._compile_backend = "inductor"
170 if oneccl_imported_p:
171 self._communication_backend_name = 'ccl'
172 else:
173 # fallback to gloo if oneccl_binding_for_pytorch is not installed
174 self._communication_backend_name = 'gloo'
175 try:
176 import psutil
177 mem = psutil.Process().memory_info().rss
178 self.max_mem = mem
179 except ImportError as e:
180 self.max_mem = 0
181
182 def is_synchronized_device(self):
183 return True

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected