Skip to content

ChiragMorajkar03/IPLScorePredictor

Repository files navigation

IPL Score Predictor

Overview

An interactive application that predicts IPL cricket match scores using machine learning. This tool helps forecast the final score based on various in-game parameters like current score, wickets, overs, and batting/bowling team information.

Features

  • Predict final IPL match scores using Random Forest Regression
  • Interactive Streamlit web interface for easy user interaction
  • Trained on historical IPL match data
  • Accurate predictions with typical error margin of ±10 runs
  • Support for all major IPL teams

Demo

IPL Score Predictor App

Technologies

  • Python 3.8+
  • Scikit-learn for machine learning algorithms
  • Pandas for data manipulation and analysis
  • Streamlit for interactive web application
  • XGBoost for gradient boosting framework
  • Matplotlib and Seaborn for data visualization

Installation

# Clone the repository
git clone https://github.com/ChiragMorajkar03/IPLScorePredictor.git

# Navigate to the project directory
cd IPLScorePredictor

# Install required packages
pip install -r requirements.txt

Usage

# Run the Streamlit app
streamlit run ipl_score_predictor.py

Input Features

  • Current score
  • Overs completed (between 5.1 to 19.5)
  • Wickets fallen
  • Batting and bowling teams
  • Runs scored in last 5 overs
  • Wickets fallen in last 5 overs

Model Development

The prediction model was built using Random Forest Regressor which outperformed other algorithms including:

  • Decision Tree
  • Linear Regression
  • Support Vector Regression
  • XGBoost
  • K-Nearest Neighbors

The complete model development process including data preprocessing, feature engineering, and model evaluation is documented in IPL_Score_Predictor.ipynb.

Data Source

The model is trained on historical IPL match data up to the 2019 season. The dataset includes detailed ball-by-ball information from multiple IPL seasons.

Model Performance

  • Training Accuracy: ~95%
  • Testing Accuracy: ~87%
  • RMSE: ~14 runs
  • Model successfully validated against multiple real IPL matches

Large Files

Due to GitHub file size limitations, the following large files are not included in this repository:

  • ml_model.pkl (129MB): The trained Random Forest model
  • ipl_data.csv (9MB): Historical IPL match data

How to Get the Large Files

You can download these files from Google Drive or request them by contacting the repository owner.

After downloading, place them in the root directory of the project.

License

This project is licensed under the MIT License - see the LICENSE file for details.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published