Skip to content

Repository files navigation

Student Performance Prediction Model Deployment

Project Overview

This project demonstrates the complete deployment of a Machine Learning model using Flask and Docker. The model predicts whether a student is likely to pass based on academic and demographic information.

The project covers the complete deployment pipeline including model training, API creation, Docker containerization, and API testing.


Features

  • Student performance prediction
  • Machine Learning model deployment using Flask
  • REST API for predictions
  • Docker containerization
  • API testing using Postman
  • Ready for cloud deployment

Project Structure

Student-Model-Deployment
│
├── app.py
├── train_model.py
├── model.pkl
├── StudentsPerformance.csv
├── Dockerfile
├── requirements.txt
├── README.md
├── Report.pdf
├── .gitignore
└── screenshots
    ├── docker-build.png
    ├── docker-running.png
    ├── postman-api.png
    ├── browser-homepage.png
    └── docker-terminal.png   

Dataset

Dataset: Students Performance Dataset

Features used:

  • Gender
  • Race/Ethnicity
  • Parental Level of Education
  • Lunch
  • Test Preparation Course
  • Math Score
  • Reading Score
  • Writing Score
  • Average Score

Target:

  • Pass (1)
  • Fail (0)

Technologies Used

  • Python
  • Pandas
  • NumPy
  • Scikit-learn
  • Flask
  • Docker
  • Postman

Workflow

Dataset
    ↓
Preprocessing
    ↓
Model Training
    ↓
Save Model (model.pkl)
    ↓
Flask API
    ↓
Docker Image
    ↓
Docker Container
    ↓
Prediction API

Docker Commands

Build Docker Image

docker build -t student-api .

Run Docker Container

docker run -p 5000:5000 student-api

View Running Containers

docker ps

View Docker Images

docker images

API Endpoint

Home

GET /

Returns

Student Performance Prediction API is Running!

Prediction Endpoint

POST /predict

Example JSON

{
    "gender": 1,
    "race/ethnicity": 2,
    "parental level of education": 3,
    "lunch": 1,
    "test preparation course": 1,
    "math score": 80,
    "reading score": 85,
    "writing score": 90,
    "Average score": 85
}

Example Response

{
    "Prediction": 1
}

Results

  • Flask API Successfully Created
  • Docker Image Successfully Built
  • Docker Container Successfully Executed
  • Prediction API Successfully Tested Using Postman

Learning Outcomes

  • Machine Learning Model Deployment
  • Flask API Development
  • Docker Containerization
  • REST API Testing
  • Production Deployment Basics

Author

Zaara Khan

Summer Internship Project 2026

About

Student Performance Prediction API built using Flask and Docker. A complete machine learning deployment project with REST API and containerization.

Topics

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages