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

python model server #15

Closed
BrentDorsey opened this issue Dec 7, 2017 · 12 comments
Closed

python model server #15

BrentDorsey opened this issue Dec 7, 2017 · 12 comments

Comments

@BrentDorsey
Copy link

BrentDorsey commented Dec 7, 2017

@aronchick / @jlewi - I enjoyed the BoF: Machine Learning on Kubernetes talk this evening, thanks for organizing it!

It would be great if kubeflow could include a Python ML model container with support for:

  • conda environment.yml requirements management
    • I use conda to build production ML containers that support multiple model types including
      • scikit-learn
      • theano
      • xgboost gradient boosted trees
  • gRPC and REST Prediction API's with Swagger documentation
  • horizontal pod autoscaling
  • prometheus application and system metrics
@yuvipanda
Copy link
Contributor

For building user images, we (at Project Jupyter) have built http://github.com/jupyter/repo2docker. https://github.com/jupyterhub/binderhub (deployed at mybinder.org) is a JupyterHub service that lets you dynamically build & run images based on a git repo (heroku style!). Perhaps that'll be cool to have?

@jlewi
Copy link
Contributor

jlewi commented Dec 7, 2017

@BrentDorsey We definitely need containers suitable for serving a variety of models. I think a lot of companies have already developed this piece. For example seldon has defined a prediction API with implementations for various model types.

So hopefully we can figure out how to leverage one or more of the existing solutions rather than developing a new one.

@yuvipanda I'd love to understand binderhub more. One of the problems we have right now is if you're developing on cluster (e.g. via Juptyerlab thank you for that) and writing a program (e.g. TF) we need to build a container from within the cluster. Right now I don't have a good solution for building docker images from within the cluster. It sounds like binderhub might solve this problem.

/cc @cliveseldon

@BrentDorsey
Copy link
Author

@jlewi - I like Pipeline.AI's prediction API, of course I'm biased as I'm a Pipeline.AI committer.

@yuvipanda - I'd also love to understand more about binderhub.

@jlewi
Copy link
Contributor

jlewi commented Dec 7, 2017

@BrentDorsey Do you have a pointer to AI's prediction server? I had trouble finding it in the repo.

@BrentDorsey
Copy link
Author

BrentDorsey commented Dec 7, 2017 via email

@ukclivecox
Copy link
Contributor

Hi,

I work for Seldon, referenced above by @jlewi

We have pushed our seldon-core product to github https://github.com/SeldonIO/seldon-core

It's goals are to allow generic machine learning models to be deployed on Kubernetes. It would be great to get some feedback and how this contributes to this issue and more generally for the deployment side of KubeFlow.

@aronchick
Copy link
Contributor

Thanks so much for letting us know, @cliveseldon! I think the overlap here is really strong, and would love to collaborate/include Seldon-core.

Do you have any thoughts on whether or not it would be monolithic, or break it down to component parts? It does a lot of different things, and was just curious about your philosophy.

@ukclivecox
Copy link
Contributor

Thanks @aronchick We're focused just on serving, not training. The core of what we provide is allow runtime graphs to be specified via a CRD. Those graphs may contain containers that are microservices which expose ML predictions but also routers (e.g., AB routing), combiners (e.g., ensembling), transformers (e.g., feature transforms) which may also be microservices inside containers.

At present this functionality is handled by 3 components that run in kubernetes, an operator to handle the CRD, an engine to handle the request/response service mesh described by your graph and an API front end that exposes these to the outside world as gRPC and REST. All this is quite tightly coupled to the CRD. So I suppose these parts would be similar to the TensorFlow serving part of the present KubeFlow except aiming to allow more complex graphs and generic ML runtime Tools (thus the discussion in this issue).

There is also Prometheus, Grafana (for metrics and a dashboard) and Kafka (and thus zookeeper) in the current helm chart but its not core and could be replaced/ignored.

@aronchick
Copy link
Contributor

Oh for sure but, unless I misunderstand, Seldon-core also handles packaging of the model for serving? If it's limited to serving, then I totally agree with you. When I was referring to components, it was more the different stages of a pipeline.

@ukclivecox
Copy link
Contributor

Yes, we provide a generic API for prediction models to handle request/responses. At a high level we want to make it easy to add runtime models so either the data scientist can do it themselves (dockerize their model and expose a REST/gRPC endpoint that respects the API) and/or we plan to provide some automated wrappers to make this easy.

So to be clear, packaging of the model is separate so could be done outside the project.

@jlewi
Copy link
Contributor

jlewi commented Dec 23, 2017

I spent some time looking at it this morning. The Seldon prediction graph and CRD looks super cool and should be pretty easy to incorporate.

I think we would do something very similar to what we do for the TfJob operator.

We can create a ksonnet package to deploy the SeldonDeployment CRD. At this point I believe users should just be able to create SeldonDeployment's and they would work. We could also deploy the Grafana and Prometheus stuff but it might make sense to make that a separate ksonnet package or include it in the core ksonnet package.

/cc @cliveseldon @aronchick

@jlewi
Copy link
Contributor

jlewi commented Mar 7, 2018

Seldon is now available as part of Kubeflow. So I'm closing this issue.

@jlewi jlewi closed this as completed Mar 7, 2018
kimwnasptd pushed a commit to arrikto/kubeflow that referenced this issue Mar 5, 2019
@jlewi jlewi added this to To Do in Needs Triage Jul 26, 2019
@jlewi jlewi removed this from To Do in Needs Triage Jul 26, 2019
yanniszark pushed a commit to arrikto/kubeflow that referenced this issue Nov 1, 2019
* update readme

* add centraldashboard
harshad16 added a commit to harshad16/odh-kubeflow that referenced this issue Aug 9, 2023
Sync RHODS 1.31 branch with v1.7 ODH branch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants