Skip to content

Commit

Permalink
Add test to comms
Browse files Browse the repository at this point in the history
  • Loading branch information
VibhuJawa committed Mar 14, 2024
1 parent a0e2756 commit 7051bbb
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions python/raft-dask/raft_dask/test/test_comms.py
Original file line number Diff line number Diff line change
Expand Up @@ -354,3 +354,16 @@ def test_device_multicast_sendrecv(n_trials, client):
wait(dfs, timeout=5)

assert list(map(lambda x: x.result(), dfs))


@pytest.mark.nccl
@pytest.mark.parametrize(
"subset", [slice(-1, None), slice(1), slice(None, None, -2)]
)
def test_comm_init_worker_subset(client, subset):
# Basic test that initializing a subset of workers is fine
cb = Comms(comms_p2p=True, verbose=True)

workers = list(client.scheduler_info()["workers"].keys())
workers = workers[subset]
cb.init(workers=workers)

0 comments on commit 7051bbb

Please sign in to comment.