Giter Club home page Giter Club logo

tdf-starters-rul's Introduction

TDF Starters Remaining-Useful-Life (RUL)

Intro

This little project uses a neural network with LSTM-cells to predict the career end of Tour de France starters.
To train the network, data about Tour de France starters between 1995 to 2019 from the excellent ressource https://www.procyclingstats.com has been scraped. The scraped data was then brought into the long-format and some features such as a cumulative count of years riding for a WorldTour/ProContinental/Continental-Team have been added. This data was then fed into a rather simple neural network with two layers of LSTM cells and a dense output layer with one cell and a linear activation function. The final model resulted in a RMSE of 2.426 and R2 of 0.742. The data can be found on Kaggle: https://www.kaggle.com/lukassteger/career-statistics-tdf-starters-19952019 The model therefore gives a rough estimate on when a rider will end his career, but should also be seen in the light of the project's weaknesses: Data quality could be enhanced, as riders with breaks in their careers such as doping-bans or being with out a contract are included in the dataset. Also features such as height or weight, were not included due to missing data. Further, the integration of non-time varying variables could be done via a multi-input network architecture. The network's hyperparameters and the number of features could be enhanced in the future, in order to obtain better results. Inspirations for this project were taken from RUL-projects such as https://github.com/gm-spacagna/deep-ttf/ and https://github.com/LahiruJayasinghe/RUL-Net Another way to approach is project is to take it as a classification problem (eg. Is rider XY still active in 5 years? Yes/No) rather than a regression problem. Unfortunately does Github not support the ipywidgets and in order to interactively explore the model's results it need to be opened as a Jupyter notebook.

Results

Fist let's have a look at the scraped and tranformed data:

There are 1358 riders in the dataset, 890 of those are retired and 468 are still considered as active.

retired_active

Looking only at the career length of the retired riders, the average career length is 13.8: Career Length

The predictions of the trained model are reasonable and give a rough estimate of a rider's career.
Scatterplot of the test set:
scatter_plot

And a two examples of the results on a rider level:
Peter Sagan PS_plot Robert Hunter RH_plot

I hope you enjoy this project and let me know in case you have any questions or comments!

tdf-starters-rul's People

Contributors

quickcoffee avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.