Football is one of the most famous and well-known sports around the globe. Born in 1863 in England, this kind of sport has a lot of fans worldwide.
The football World Cup is one the biggest global events that are hosted once every four years by a specific country where many qualified teams compete to win the World Cup title.
The 20th of November 2022, has been an extremely important day for football fans around the globe. This day marks the beginning of the World Cup 2022 and for the first time, it is hosted by Qatar which is a small country but bigger than you ever thought.
In this project, I worked on predicting the winner of the group-stage games using a multi-class classifier that uses multiple data sources to classify game results into 3 categories (Home,Draw, and Away).
I also wrote an article on Medium where I detailed the steps to implement this project and listed the results that I got.
-
First you need to clone the repository to your local machine using this command:
git clone https://github.com/aminebennaji19/FIFA-World-Cup-Qatar-2022.git
-
After cloning the repository, you need to install the install the project requirements.
-
PS: This project was developed using Python3.7
pip3 install -r requirements.txt
-
data: Folder containing the data files.
- 1-World_cup2022.csv: The World Cup player 2022 stats dataset.
- WorldCups.csv: The World Cup achievements dataset.
- fifa_ranking-2022-10-06.csv: The Fifa rankings dataset.
- results.csv: The International football results dataset.
-
results:Folder holding the results of our prediction and the best model.
- best_classifier.pkl: The exported model pickle file.
- remaining_group_stage_games_world_cup_2022.csv: The exported model pickle file.
-
figures: Folder including the necessary images for the Readme file.
-
requirements.txt: The project requirements file.
-
World-Cup-2022-Predictions.ipynb: Jupyter Notebook including the World Cup 2022 group stage predictions.
In this project:
-
We Explored, pre-processed and prepared the data to use following the ETL (Extract, Transform, Load) process.
-
We Trained, evaluated, tested and optimized the classifier on test data and a held-out test split (world cup games).
-
We Fine-tuned the model to improve its performance.
-
We Predicted the winners of the group stage phase.
Take a look at this blog to understand what we did in details and also on the code implementation.
The results that we had are the very first results and can be improved in the near future by one of these potential solutions:
-
Add, and clean more data where we can study the outliers, and the skewness of the data and consider the balance of the classes. Use more potential data sources like the latest player stats to include performance indicators for each team.
-
Include the already-played game results of the group stage of this edition into the training set maybe they’ll add something beneficial to conclude the World Cup winner.
-
Deploy this work on a web application to showcase its added value.
This project is the final part of the Udacity Data Science Nanodegree program that is really helpful and practical. I would like to dedicate this work to Kaggle for sharing the data and findings between members and make everything possible by unlocking the hidden secrets of data.
Feel free to use this code, sharing it with the community and contact me on LinkedIn if there's anything related to this project.