Skip to content

feat: add streaming to map_batches #5

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

wangrunji0408
Copy link
Collaborator

This PR introduces a streaming option to the map_batches function. When streaming=true, the user function will receive an iterator and return an iterator. This enables users to customize the streaming logic for data processing, such as parallelizing CPU and GPU operations to improve utilization of both resources. However, this approach is still not straightforward enough for users. In the future, we plan to allow users to pass multiple functions, which will automatically be executed in parallel across different threads in a pipelined manner.

Signed-off-by: Runji Wang <[email protected]>
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

Successfully merging this pull request may close these issues.

1 participant