MCPcopy Create free account
hub / github.com/Oneflow-Inc/oneflow / node_size

Function node_size

python/oneflow/framework/unittest.py:104–112  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

102
103
104def node_size():
105 node_num_from_env = os.getenv("ONEFLOW_TEST_NODE_NUM", None)
106 if node_num_from_env:
107 return int(node_num_from_env)
108 elif has_node_list():
109 node_list_from_env = node_list()
110 return len(node_list_from_env)
111 else:
112 return 1
113
114
115def has_world_size():

Callers 1

skip_unlessFunction · 0.85

Calls 2

has_node_listFunction · 0.85
node_listFunction · 0.85

Tested by

no test coverage detected