-
Notifications
You must be signed in to change notification settings - Fork 5.4k
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
[Core] Ray-based concurrent.futures.Executor #30826
Conversation
Co-authored-by: Mohamed Nidabdella <mohamed.nidabdella@tweag.io> Signed-off-by: Johann Eicher <johann.eicher@tweag.io>
Co-authored-by: Mohamed Nidabdella <mohamed.nidabdella@tweag.io> Signed-off-by: Johann Eicher <johann.eicher@tweag.io>
Signed-off-by: Johann Eicher <johann.eicher@tweag.io>
Signed-off-by: Johann Eicher <johann.eicher@tweag.io>
Signed-off-by: Johann Eicher <johann.eicher@tweag.io>
Signed-off-by: Johann Eicher <johann.eicher@tweag.io>
Signed-off-by: Johann Eicher <johann.eicher@tweag.io>
Signed-off-by: Johann Eicher <johann.eicher@tweag.io>
Signed-off-by: mohamed <mohamed.nidabdella@tweag.io>
The three failing tests don't seem to have anything to do with our contribution. The Docker Bootstrap test, at the very least, failed because Ubuntu failed to update. Perhaps someone at Ray could shed some light on the failures? |
sorry for the delay. I will review this tomorrow! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm actually before deep diving into the review, is it currently only support submitting 1 task? It looks like current subclasses of Executor (ProcessExecutor and ThreadPoolExecutor) both has a concept of pool (max_workers). Should we have the same thing?
python/ray/util/ray_executor.py
Outdated
return fn(*args, **kwargs) | ||
|
||
self.__remote_fn = remote_fn | ||
self.context = ray.init(ignore_reinit_error=True, **kwargs) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we expose context as @Property method?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The initial intent was that RayExecutor
will be used in context (the with
python context). So once we exit the context, ray is shutdown. I don't think we need to expose context
as @property
method, at least for now
@rkooo567 can you take another look at this ? |
Thanks @rkooo567! I've refactored quite a bit to make multiple task submission much clearer. The executor now has a |
thanks for the update and sorry for the delay! I am planning to review this tomorrow (have been off around new year!) |
btw there are lots of test failures. Do you mind merging the latest master? |
@rkooo567 any update on this? |
Hi @nidabdella, Could you reply to the comments I posted above? We can also schedule a meeting to go through the design and make sure we are aligned. |
Thanks @jjyao, I've reverted to an Actor-based model. In the meantime, I've pinged you on Slack. Let's try and organise a chat to make sure we're on the same page. |
I am a bit occupied lately, so I will rely on @jjyao to finish the review! |
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 14 days if no further activity occurs. Thank you for your contributions.
|
Hi @jeicher, do you have any updates on this? |
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 14 days if no further activity occurs. Thank you for your contributions.
|
Hey guys, I'll be back from leave soon. Hoping to get to this in the near future! |
Hi again! The issue will be closed because there has been no more activity in the 14 days since the last message. Please feel free to reopen or open a new issue if you'd still like it to be addressed. Again, you can always ask for help on our discussion forum or Ray's public slack channel. Thanks again for opening the issue! |
Just chiming in to say I love the idea :) |
@fkaleo I'll have a finished solution for this very soon 👍🏻 |
Why are these changes needed?
This PR provides RayExecutor, a drop-in replacement for ProcessPoolExecutor and ThreadPoolExecutor from concurrent.futures, which executes tasks on a Ray cluster.
Related issue number
Closes #29456
Checks
git commit -s
) in this PR.scripts/format.sh
to lint the changes in this PR.