Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/deepspeedai/DeepSpeed
/ get_ma_status
Function
get_ma_status
deepspeed/runtime/utils.py:804–807 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
802
803
804
def
get_ma_status():
805
if
dist.is_initialized() and not dist.get_rank() == 0:
806
return
0
807
return
get_accelerator().memory_allocated()
808
809
810
def
empty_cache():
Callers
1
forward
Method · 0.85
Calls
4
get_accelerator
Function · 0.90
is_initialized
Method · 0.45
get_rank
Method · 0.45
memory_allocated
Method · 0.45
Tested by
no test coverage detected