Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/bitsandbytes-foundation/bitsandbytes
/ sync_gpu
Function
sync_gpu
bitsandbytes/utils.py:204–208 ·
view source on GitHub ↗
(t: torch.Tensor)
Source
from the content-addressed store, hash-verified
202
203
204
def
sync_gpu(t: torch.Tensor):
205
if
t.device.type ==
"cuda"
:
206
torch.cuda.synchronize()
207
elif
t.device.type ==
"xpu"
:
208
torch.xpu.synchronize()
Callers
2
step
Method · 0.90
test_benchmark_blockwise
Function · 0.90
Calls
no outgoing calls
Tested by
1
test_benchmark_blockwise
Function · 0.72