This is a Machine Learning Project that predicts the cricket score based on input parameters such as batting team, bowling team, city, current score, overs bowled, wickets out, and runs in the last 5 overs. I collaborated with my classmates Abeer and Rafin here. We have tried to modify and enhance further the project found in KNOWLEDGE DOCTOR YouTube channel. We altered the hyperparameters of Random Forest and XGBoost algorithms and compared the performances.
- Predicts the final score of a cricket match based on current match conditions.
- Uses Bootstrap for responsive design and styling.
- Validates user input to ensure meaningful predictions.
- HTML
- CSS (Bootstrap)
- JavaScript (jQuery)
- Flask (for backend logic)
- Python (for prediction logic)
- Jupyter Notebook (for training the model)
-
Clone the repository:
git clone https://github.com/yourusername/cricket-score-predictor.git cd cricket-score-predictor -
Install required packages: flask, sci-kit learn, pandas, etc.
-
Run app.py
pipe = pickle.load(open('x.pkl', 'rb')) - Here, replace x with the name of the .pkl file which is generated by jupyter.
To add more teams or cities, update the dropdown options in the index.html file. To change the default teams or city, modify the JavaScript logic in the index.html file to set the desired default values. To adjust the prediction logic, update the backend logic in app.py.
Select the batting team, bowling team, and city from the dropdown menus. Enter the current score, overs bowled, wickets out, and runs scored in the last 5 overs. Click the "Predict Score" button.
Contributions are welcome! Please fork the repository and submit a pull request for any features, bug fixes, or improvements.