Let´s talk about PlayerTrack

Checha Giudice
8 min readJun 24, 2021

--

Ultimate Track,
for ultimate Results

Introduction

We love sports. I love sports.

When my team and I started speaking about our last final project we wanted to create something we were passionate about. We worked with each other in so many projects before we knew everything about each other.

We knew we three loved sports. I (Cecilia Giudice) play field hockey in two amateur teams, Julian Arbini played and coached in a basketball team, and Soledad Frechou played football (soccer for those ignorant).

For me personally, sports have always had a great impact in my life. My own parents love football, and love watching football too. They always wanted their children to play in some kind of sports, any team sports, because they believe it builds character, teaches you how to be a team player, about frustration and how to deal with it, and to never give up.

Sports are part of my life. Every moment I was down about something about my life, my team was there to support me and I could always channelize the anger I had in my game. Sports make me happy: whether I’m playing field hockey with my team, speaking about football with my family or whatching a game with my friends, it fills me with such happiness only another sports fan could understand.

The Final Countdown.

Talking about that final project, we decided to do it about sports. Knowing our strengths it was easy to choose who would do what.

But first we needed a purpose. Yes, we wanted our app to be about sports, but what exactly could it do? We needed insight, someone who had a problem to fix, for example.

Given that where I live you can always know someone who knows someone, we contacted with a physical trainer from a known local professional rugby team. He told us his team was competing, at that moment, in an international tournament, what their daily routine was and which problems tecnology would solve.

Not one of us knew enough about rugby, so understanding the sport was a fun challenge.

The problems he introduced us weren’t that challenging to us (not trying to be humble, plain honest). So, we asked if they were using some kind of tecnology already to improve the teams performance.

Nowadays, professional teams (and some amateurs too), use GPS trackers to monitor a players speed, heart rate, distance and many other variables the team staff take into account to upgrade the players performance. These GPS trackers give so much raw data it’s impossible to analize it all at once. Consider this rugby team has 30 players (meaning 30 GPS trakers), who use this tecnology not only during games, but also during training sessions.

The top bra this player is using has a GPS on the back that get all the relevant information.

The GPS spits .xlml files (an Excel table), with all of these variables already mentioned but no analisys, and this was our inspiration for our project.

What if we could use this raw information to improve this team performance on the field? What if our app could make a team, from any kind of sport, win an international tournament.

An ambitious project that would be. So, we took on the challenge.

For this project to be carried out we needed REAL data, and REAL facts, so we could get REAL results and conclussions. The physical trainer from the rugby team gave us all the info and data from the tournament games we asked for, with the only condition to keep it as private as possible thats why we changed the name of the team, the oppossing teams and players, and kept the app local to protect the team and players.

Julian took on the task to analize the data and see if he could find out if we could ACTUALLY create out of this raw data. With a lot of patience, he created some new variables out of those excel files, and knew from that which players got injuries and why. Not all players played all the games from that tournament, but he knew, and confirmed later with the trainer, which ones didn’t play because of injuries and which ones because the trainer didn’t placed them during the game.

After this incredible discoverment, we decided what our app was going to be about: a predictive model based on these new variable and figure if it was possible to foresee, predict and eventually prevent player injuries. Our app would be for team sports who want to avoid their best players to take on injuries so that they could get far on any competition.

That’s how PlayerTrack was born.

Official logo

We organized ourselves and used Trello to divide the tasks and estimate how much time it would take each task to complete. Julian would dig deeper on the creation of new variables, and create the database for those variables. Meanwhile, Soledad and I would create the whole front-end and start to work on the back-end, specifically how the information from the database would flow through the app.

Architecture.

The idea was simple, the execution not so much.

There would be two types of users: player and staff. The player would only enter the app to complete a form, the app will save in the database, and that informatio the user staff will later analyze and use as they need.

View from the player profile in the staff user section.

The staff user will be provided of the raw data from the GPS, and the new variables created, showing also the completed forms of all players (and a list of those who did’t complete it), along with an injury table to keep track of recovery dates and types of injuries and stuff.

Basic diagram of PlayerTrack.

The deployed application is server based. Each client will have within their server their own MySQL database with specific and secure users and passwords. Within each database, the user addition will be managed by the client themselves and the GPS input automated. This can be done by taking the XML GPS exports and querying them into the database, like shown in the diagram.

We created the whole front end in pure HTML5, styled in CSS3 with the Bootstrap Framework because both Soledad and I felt comfortable enough with them and wanted to deepend our knowledge about them, the same thing happend with JQuery for me, and let me the chance to explain it to both Soledad and Julian and whay Javascript was best for this kind of project. As web framework, we used Python’s Flask and Jinja because of its scalability and used MySQL as the database for storage, all of this constituting an MVC architecture.

Challenges

Even though we (Julian, Soledad and myself) worked together so many times before, in so many different projects, PlayerTrack was endgame.

From my perspective, the flow of information throug the app was challenging enough. The player user would complete a simple form, that information had to be stored in the data base and then queried and showed in the staff user section for player profile. Meaning the info provided b the player would be entered in the HTML5 form, taken by JQuery and analized and stored with Python’s Flask.

Simple, huh?

Add to the mix all the raw GPS data that had to be saved in the database, analized with Javascript and shown in the HTML5 docs with Charts.js. It was like some kind of domino effect. We fixed one mistake and something that had always worked, suddenly and out of nowhere it would stop working.

It was a nightmare, don’t get me wrong. We built ourselves of patience and going back over and over our code to correct that spelling mistake or worng variable we were using and got our app working more than fine.

Learning from experience

These two week of hard work really tested us not only as programmers but as professionals too.

By failing and knowing where we fail, and being able to correct it deepen our knoledge in all of the tecnologies we used to succeed in the building of PlayerTrack.

You always know you can do better after you’ve “finished” the project, because everything can be upgraded. For instance, in the user staff dashboard a list of players is displayed, and tells which player completed their daily form, and who did not. You can only access the form when you access a player profile specifically, and not form the list itself. One change I would make would be that once you hover the name of the player in the list it displays the form in some kind of mock up or something like that.

I can not tell enough how much this experience helped me become a better programmer. My knowledge in Python’s Flask and Jinja was pretty basic, to be honest, and the creation of the app really helped me in understanding how the information flows around and how to make it flow in the direction I wanted it to.

Also, I have always felt comfortable with Javascipt and Jquery but combining it with Python was new, and actually exciting.

I loved creating, building and programming this app. Being given the opportunity to combine two passions, sports and programming, is something I would like to try again in the future.

About me…

I am a Software Developer and Graphic and Web designer. My favorite football team is Liverpool Football Club (England), and even though I don’t believe in the horoscope, I love reading my daily sign predictions on Instragram because that’s what Libras do. And if you make me choose between Vim and Emas for any project, I will always choose Emacs (I regret nothing).

About the project…

--

--