MCPcopy Index your code
hub / github.com/huggingface/diffusers / device_synchronize

Function device_synchronize

src/diffusers/utils/torch_utils.py:312–316  ·  view source on GitHub ↗
(device_type: str | None = None)

Source from the content-addressed store, hash-verified

310
311
312def device_synchronize(device_type: str | None = None):
313 if device_type is None:
314 device_type = get_device()
315 device_mod = getattr(torch, device_type, torch.cuda)
316 device_mod.synchronize()
317
318
319def enable_full_determinism():

Callers

nothing calls this directly

Calls 1

get_deviceFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…