Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[REVIEW] Add scheduler_file argument to support MNMG setup #1593

Merged
merged 10 commits into from
Jun 22, 2023

Conversation

VibhuJawa
Copy link
Member

@VibhuJawa VibhuJawa commented Jun 13, 2023

Add scheduler_file argument to support MNMG setup

Overview:

The primary goal is to provide more flexibility and adaptability in how the Dask cluster for testing is configured.

Changes:

  1. Allow connecting to an existing cluster
  • The creation of the LocalCUDACluster instances is now contingent on the presence of a SCHEDULER_FILE environment variable. If this variable exists, the path to the Dask scheduler file is returned instead of creating a new cluster. This change allows the use of pre-existing clusters specified via the SCHEDULER_FILE environment variable.
  1. Remove UCX related flags as they are no longer needed

This could help in situations where test scenarios need to be conducted on a specific pre-existing cluster (especially for MNMG setups) .

Testing:

I tested using the following setup:
Start Cluster:

dask scheduler --scheduler-file /raid/vjawa/scheduler.json &
dask-cuda-worker --scheduler-file /raid/vjawa/scheduler.json

Run Tests:

export SCHEDULER_FILE=/raid/vjawa/scheduler.json 
cd /home/nfs/vjawa/raft/python/raft-dask/raft_dask/test
pytest .

@cjnolet cjnolet added improvement Improvement / enhancement to an existing function non-breaking Non-breaking change labels Jun 13, 2023
python/raft-dask/raft_dask/test/__init__.py Outdated Show resolved Hide resolved
Comment on lines -27 to -40
initialize.initialize(
create_cuda_context=True,
enable_tcp_over_ucx=enable_tcp_over_ucx,
enable_nvlink=enable_nvlink,
enable_infiniband=enable_infiniband,
)
cluster = LocalCUDACluster(
protocol="ucx",
enable_tcp_over_ucx=enable_tcp_over_ucx,
enable_nvlink=enable_nvlink,
enable_infiniband=enable_infiniband,
)
yield cluster
cluster.close()
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@VibhuJawa VibhuJawa changed the title [WIP] Add scheduler_file argument to support MNMG setup [REVIEW] Add scheduler_file argument to support MNMG setup Jun 13, 2023
@VibhuJawa VibhuJawa marked this pull request as ready for review June 13, 2023 22:04
@VibhuJawa VibhuJawa requested a review from a team as a code owner June 13, 2023 22:04
yield client
client.close()


@pytest.fixture()
def ucx_client(ucx_cluster):
client = Client(cluster)
client = create_client(ucx_cluster)
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this was a bug previously where we passed cluster instead of ucx_cluster .

Will revert if this was intentional.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needed to add this as we run tests on workers and scheduler and this module needs to be importable for that to happen in dask when running on a non local cluster.

@VibhuJawa VibhuJawa changed the title [REVIEW] Add scheduler_file argument to support MNMG setup [WIP] Add scheduler_file argument to support MNMG setup Jun 22, 2023
@VibhuJawa VibhuJawa changed the title [WIP] Add scheduler_file argument to support MNMG setup [REVIEW] Add scheduler_file argument to support MNMG setup Jun 22, 2023
Copy link
Member

@cjnolet cjnolet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thanks @VibhuJawa!

@cjnolet
Copy link
Member

cjnolet commented Jun 22, 2023

/merge

@rapids-bot rapids-bot bot merged commit 6f0abae into rapidsai:branch-23.08 Jun 22, 2023
@VibhuJawa VibhuJawa deleted the enabme_mnmg_tests branch June 26, 2023 16:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improvement Improvement / enhancement to an existing function non-breaking Non-breaking change python
Projects
Development

Successfully merging this pull request may close these issues.

2 participants