# Example MLflow project ## Overview This is an example MLflow project for the [MLflow Quickstart](https://www.mlflow.org/docs/latest/quickstart.html#quickstart) documentation. Using both the [UCI Wine Quality dataset](http://archive.ics.uci.edu/ml/datasets/Wine+Quality) (by P. Cortez, A. Cerdeira, F. Almeida, T. Matos and J. Reis.) and Elastic Net to predict quality, we create an MLflow project. Moreover, The example uses MLproject to set up a Conda environment, define parameter types and defaults, entry point for training, etc. ## Instructions If you reached this repository from going through the [MLflow Quickstart](https://www.mlflow.org/docs/latest/quickstart.html#quickstart) documentation, please follow these instructions (else, feel free to independently go through the material yourself): 1 ) Per the [Running MLflow Projects](https://www.mlflow.org/docs/latest/quickstart.html#running-mlflow-projects) section, run the following: `mlflow run tutorial -P alpha=0.5` `mlflow run git@github.com:mlflow/mlflow-example.git -P alpha=5` > **Note:** If you are receiving git permission issues, please _git clone_ this repository. > > Thereafter, run command: > > `mlflow run mlflow-example -P alpha=0.5` 2 ) Per the [Saving and Serving Models](https://www.mlflow.org/docs/latest/quickstart.html#saving-and-serving-models) section, run: `python sklearn_logistic_regression/train.py` Therafter, to serve the scikit-learn model through a REST server, run: `mlflow sklearn serve -r model` Now, run `curl -d '[{"x": 1}, {"x": -1}]' -H 'Content-Type: application/json' -X POST localhost:5000/invocations` Congrats, you are done! Please refer back to the [MLflow Quickstart](https://www.mlflow.org/docs/latest/quickstart.html#quickstart) documentation or feel free to play around more with MLflow! Cheers!