Code Monkey home page Code Monkey logo

abhishekrs4 / ml_water_potability Goto Github PK

View Code? Open in Web Editor NEW
2.0 1.0 1.0 7.82 MB

ML model deployment using docker, kubernetes; API deployment with FastAPI; and MLOps using MLFlow for water potability dataset

License: BSD 3-Clause "New" or "Revised" License

Python 98.35% Dockerfile 1.65%
machine-learning machine-learning-model machine-learning-model-deployment machine-learning-model-management scikit-learn-python water-potability water-quality mlflow mlflow-model mlflow-sklearn

ml_water_potability's Introduction

ML application for water potability classification

Dataset Info

  • The source of the dataset is the following repo
  • The task is a binary classification task to predict the water potability given the different feature measurements of the water quality
  • The dataset sample contains about 3.2K samples

Repo Info

  • This repo contains a water potability Machine Learning FastAPI application deployment
  • For the MLOps, MLFlow has been utilized
  • For deployment, an API has been developed and deployed using FastAPI and docker
  • For the training, the dataset is split into 90% - 10% for train and test sets respectively
  • For getting the latest model from the mlflow logs for production, use the script get_model_for_production.py
  • The python packages are listed in requirements.txt
  • The docker container can be deployed using Dockerfile
  • For training and logging the model, use the modeling/ml_model_dev.py script
  • The FastAPI app deployment code is in app.py script
  • To test the deployed FastAPI app on a local machine, the test_post_request.py script can be used

Docker deployment instructions on a local machine

  • To build the container, run the following command
docker build -t fastapi_water_potability .
  • To the run the container, run the following command
docker run -p 5000:5000 -t fastapi_water_potability

Kubernetes deployment instructions on a local machine

HuggingFace deployment

  • The FastAPI application with appropriate changes has also been deployed to HuggingFace
  • To test the deployed FastAPI app on HuggingFace, use the test_post_request.py script in the HuggingFace repo since the endpoint is different

Documentation

The documentation generated with sphinx is available in docs/_build/html/index.html

ml_water_potability's People

Contributors

abhishekrs4 avatar

Stargazers

 avatar

Watchers

 avatar

Forkers

tranchauau

ml_water_potability's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.