Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/alinlab/SelfPatch
/ get_world_size
Function
get_world_size
utils.py:411–414 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
409
410
411
def
get_world_size():
412
if
not is_dist_avail_and_initialized():
413
return
1
414
return
dist.get_world_size()
415
416
417
def
get_rank():
Callers
1
reduce_dict
Function · 0.85
Calls
1
is_dist_avail_and_initialized
Function · 0.85
Tested by
no test coverage detected