RapidsMPF SPMD mode - #21619
Conversation
d1da9cd to
204eebf
Compare
| The concatenated output DataFrame and, if ``collect_metadata`` is | ||
| True, the list of channel metadata objects; otherwise ``None``. | ||
| """ | ||
| if config_options.executor.runtime != "rapidsmpf": |
There was a problem hiding this comment.
There's quite a bit of duplication between this and evaluate_pipeline, though I haven't looked closely to see what the difference is.
There was a problem hiding this comment.
I prefer to keep them separate for now. The long-term goal is to remove most of evaluate_pipeline, and eventually drop Dask entirely once this implementation matures.
| if not bootstrap.is_running_with_rrun(): | ||
| raise RuntimeError( | ||
| "spmd_execution() requires the rrun launcher. " | ||
| "Use `rrun -n <nproc> python -m pytest ...` to run SPMD tests." |
There was a problem hiding this comment.
Is there any chance that a user could hit this error, say by misconfiguring their engine? If so, I think we'd want a friendlier error message, ideally telling them what they did wrong.
There was a problem hiding this comment.
Yeah, I think we shouldn't mention pytest here.
There was a problem hiding this comment.
renamed to:
raise RuntimeError(
"spmd_execution() requires the rrun launcher. "
"Launch your script with `rrun -n <nproc> python your_script.py` "
"to enable SPMD execution."
)| Extra keyword arguments forwarded directly to | ||
| :class:`~polars.lazyframe.engine_config.GPUEngine`. For example, | ||
| pass ``parquet_options={"use_rapidsmpf_native": True}`` to enable | ||
| native Parquet reads. |
There was a problem hiding this comment.
Maybe note that "raise_on_fail", "memory_resource", "executor" are reserved, like you did for exeuctor_options?
And just confirming, we do want to hardcode raise_on_fail here? I understand why the others have to be hardcoded.
There was a problem hiding this comment.
Why do we hardcode raise_on_fail?
I have removed it here
| if not bootstrap.is_running_with_rrun(): | ||
| raise RuntimeError( | ||
| "spmd_execution() requires the rrun launcher. " | ||
| "Use `rrun -n <nproc> python -m pytest ...` to run SPMD tests." |
There was a problem hiding this comment.
Yeah, I think we shouldn't mention pytest here.
|
/merge |
This PR adds an
spmdcluster type to the streaming executor, enabling multi-GPU execution via therrunlauncher without requiring Dask.With this mode, users can run the same Python program on multiple ranks (SPMD style) and use RapidsMPF collectives directly from Python. Each rank processes its own slice of data and coordinates through collectives such as
allgather.Example
Launch with:
Running the pdsh benchmarks
Update: the benchmark update has been moved to a follow-up PR: #21652