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

Start designing shuffling algorithm #26

Open
pabloem opened this issue Jun 15, 2022 · 0 comments
Open

Start designing shuffling algorithm #26

pabloem opened this issue Jun 15, 2022 · 0 comments

Comments

@pabloem
Copy link
Collaborator

pabloem commented Jun 15, 2022

When a stage sends its output, we want to start using that to shuffle data to downstream stages.

for output in worker_handler.data_conn.input_elements(
process_bundle_id,
expect_reads,
abort_callback=lambda:
(result_future.is_done() and bool(result_future.get().error))):
if isinstance(output, beam_fn_api_pb2.Elements.Timers) and not dry_run:
output_buffers[expected_outputs[(output.transform_id, output.timer_family_id)]].append(output.data)
if isinstance(output, beam_fn_api_pb2.Elements.Data) and not dry_run:
output_buffers[expected_outputs[output.transform_id]].append(output.data)
for pcoll, buffer in output_buffers.items():
objrefs = [ray.put(buffer)]
runner_context.pcollection_buffers.put.remote(pcoll, objrefs)
output_buffers[pcoll] = objrefs

Example of shuffle implementation for Ray Datasets 1.13: ray-project/ray#23758

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant