MCPcopy
hub / github.com/deepspeedai/DeepSpeed / get_xdist_worker_id

Function get_xdist_worker_id

tests/unit/common.py:39–44  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

37
38
39def get_xdist_worker_id():
40 xdist_worker = os.environ.get('PYTEST_XDIST_WORKER', None)
41 if xdist_worker is not None:
42 xdist_worker_id = xdist_worker.replace('gw', '')
43 return int(xdist_worker_id)
44 return None
45
46
47def get_master_port(base_port=29500, port_range_size=1000):

Callers 2

get_master_portFunction · 0.85
set_accelerator_visibleFunction · 0.85

Calls 1

getMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…