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

[AIR] Remove PredictorDeployment from examples #37457

Merged
merged 40 commits into from
Jul 29, 2023

Conversation

pcmoritz
Copy link
Contributor

@pcmoritz pcmoritz commented Jul 15, 2023

Why are these changes needed?

This PR removes the AIR PredictorDeployment from examples and replaces them with Ray Serve deployments directly. This is more explicit and often time simpler and more understandable. It also reduces the number of ways in which things are done according to the Zen of Python There should be one -- and preferably only one -- obvious way to do it..

Related issue number

Checks

  • I've signed off every commit(by using the -s flag, i.e., git commit -s) in this PR.
  • I've run scripts/format.sh to lint the changes in this PR.
  • I've included any doc changes needed for https://docs.ray.io/en/master/.
    • I've added any new APIs to the API Reference. For example, if I added a
      method in Tune, I've added it in doc/source/tune/api/ under the
      corresponding .rst file.
  • I've made sure the tests are passing. Note that there might be a few flaky tests, see the recent failures at https://flakey-tests.ray.io/
  • Testing Strategy
    • Unit tests
    • Release tests
    • This PR is not tested :(

@pcmoritz pcmoritz changed the title [WIP] [AIR] Remove PredictorDeployment [AIR] Remove PredictorDeployment from examples Jul 25, 2023
Copy link
Contributor

@matthewdeng matthewdeng left a comment

Choose a reason for hiding this comment

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

Generally LGTM, and honestly cleaner than I expected 😄

Before merging:

  1. Can you add a PR description for this change?
  2. Can you verify the CI test failures are unrelated?

@@ -159,70 +159,78 @@ def send_request(**requests_kargs):


def test_simple_adder(serve_instance):
Copy link
Contributor

Choose a reason for hiding this comment

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

Do we still need these tests? Is there anything that is being tested here that is not being covered by Predictor and Serve unit tests?

Copy link
Contributor

Choose a reason for hiding this comment

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

I think it's worthwhile to test the combination of predictor deployment + serve in CI somewhere. I don't think we have anything similar in the serve unit tests at the moment.

@@ -159,70 +159,78 @@ def send_request(**requests_kargs):


def test_simple_adder(serve_instance):
Copy link
Contributor

Choose a reason for hiding this comment

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

I think it's worthwhile to test the combination of predictor deployment + serve in CI somewhere. I don't think we have anything similar in the serve unit tests at the moment.

predictor_cls=AdderPredictor,
@serve.deployment
class AdderDeployment:
def __init__(self, checkpoint):
Copy link
Contributor

Choose a reason for hiding this comment

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

type hints would be very nice here :)

@pcmoritz pcmoritz merged commit 702c36d into ray-project:master Jul 29, 2023
80 of 86 checks passed
@pcmoritz pcmoritz deleted the remove-air-predictor-deployment branch July 29, 2023 06:53
NripeshN pushed a commit to NripeshN/ray that referenced this pull request Aug 15, 2023
This PR removes the AIR PredictorDeployment from examples and replaces them with Ray Serve deployments directly. This is more explicit and often time simpler and more understandable. It also reduces the number of ways in which things are done according to the Zen of Python `There should be one -- and preferably only one -- obvious way to do it.`

Signed-off-by: NripeshN <nn2012@hw.ac.uk>
harborn pushed a commit to harborn/ray that referenced this pull request Aug 17, 2023
This PR removes the AIR PredictorDeployment from examples and replaces them with Ray Serve deployments directly. This is more explicit and often time simpler and more understandable. It also reduces the number of ways in which things are done according to the Zen of Python `There should be one -- and preferably only one -- obvious way to do it.`

Signed-off-by: harborn <gangsheng.wu@intel.com>
harborn pushed a commit to harborn/ray that referenced this pull request Aug 17, 2023
This PR removes the AIR PredictorDeployment from examples and replaces them with Ray Serve deployments directly. This is more explicit and often time simpler and more understandable. It also reduces the number of ways in which things are done according to the Zen of Python `There should be one -- and preferably only one -- obvious way to do it.`
arvind-chandra pushed a commit to lmco/ray that referenced this pull request Aug 31, 2023
This PR removes the AIR PredictorDeployment from examples and replaces them with Ray Serve deployments directly. This is more explicit and often time simpler and more understandable. It also reduces the number of ways in which things are done according to the Zen of Python `There should be one -- and preferably only one -- obvious way to do it.`

Signed-off-by: e428265 <arvind.chandramouli@lmco.com>
vymao pushed a commit to vymao/ray that referenced this pull request Oct 11, 2023
This PR removes the AIR PredictorDeployment from examples and replaces them with Ray Serve deployments directly. This is more explicit and often time simpler and more understandable. It also reduces the number of ways in which things are done according to the Zen of Python `There should be one -- and preferably only one -- obvious way to do it.`

Signed-off-by: Victor <vctr.y.m@example.com>
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.

None yet

3 participants