Skip to content

Tehnomant/PMLDL-Assignment-1-Deployment

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ML Model Deployment Project

A complete machine learning model deployment using FastAPI and Streamlit with Docker.

Project Structure

ml-deployment-project/
├── models/ # Saved ML models
├── code/
│ ├── models/ # Model training code
│ └── deployment/ # Deployment configuration
│ ├── api/ # FastAPI service
│ ├── app/ # Streamlit app
│ └── docker-compose.yml
├── data/ # Data files
└── requirements.txt # Python dependencies

Quick Start

  1. Train the model:
cd code/models
python train_model.py
  1. Deploy with Docker:
cd code/deployment
docker-compose up --build
  1. Access the applications:

Services

FastAPI Service

  • Port: 8000
  • Endpoints:
    • GET / - Service status
    • GET /health - Health check
    • POST /predict - Make predictions
    • GET /model-info - Model information

Streamlit Application

  • Port: 8501
  • Features: Interactive web interface for model predictions

Development

Local Development

# Install dependencies
pip install -r requirements.txt

# Train model
python code/models/train_model.py

# Run API locally
cd code/deployment/api
uvicorn main:app --reload

# Run app locally
cd code/deployment/app
streamlit run app.py

About

This is assignment for PMLDL course

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published