2. Configuration – Installing OpenCV

Welcome back!

Today I would like to write something about the basic software I am using to program. I will program in C++ and use a library called OpenCV, it’s the most used open source computer vision library, and there is extensive documentation, examples and tutorials, I intent to do a post especifically about all the functionalities and examples of use of OpenCV but while I don’t, more information can be found here

http://docs.opencv.org/index.html

Although the OpenCV is utilized by a lot of people, and there is a lot of support online, every time I have to install it, I end up following a diferent tutorial, with diferent configurations, and sometimes even ended up installing an older version. Today I found a pretty amazing tutorial at github and would like to share it with all of you.

http://milq.github.io/install-opencv-ubuntu-debian/

I will write a summary of things here just for reference.

1. Update Ubuntu

sudo apt-get update
sudo apt-get upgrade

2. Install Dependencies

Build tools:

sudo apt-get install build-essential cmake

GUI:

sudo apt-get install qt5-default libvtk6-dev

Media I/O:

sudo apt-get install zlib1g-dev libjpeg-dev libwebp-dev libpng-dev libtiff5-dev libjasper-dev libopenexr-dev libgdal-dev

Video I/O:

sudo apt-get install libdc1394-22-dev libavcodec-dev libavformat-dev libswscale-dev libtheora-dev libvorbis-dev libxvidcore-dev libx264-dev yasm libfaac-dev libopencore-amrnb-dev libopencore-amrwb-dev libv4l-dev libxine2-dev

Parallel programming:

sudo apt-get install libtbb-dev libeigen3-dev

Phyton:

sudo apt-get install python-dev python-tk python-numpy python3-dev python3-tk python3-numpy

Java:

sudo apt-get install ant default-jdk

Documentation:

sudo apt-get install sphinx-common texlive-latex-extra

3. Download and decompress OpenCV

Enter opencv.org and download the latest version available.
Decompress it in the file you choose.

4. Compile and install OpenCV

Use the cd command to navigate to your OpenCV directory. Then put the following in the terminal

mkdir build
cd build
cmake -DWITH_QT=ON -DWITH_OPENGL=ON -DFORCE_VTK=ON -DWITH_TBB=ON -DWITH_GDAL=ON -DWITH_XINE=ON -DBUILD_EXAMPLES=ON ..
make -i
sudo make install

That should install the OpenCV in your system, just open an example, compile and run it in the terminal to be sure everything went according to the expectations.

Thats all for now!

Igor Hueb de Castro

 

State of the Art – Videobserver

Welcome back!

Today I would like to share with you a little about a find I made because of this blog.

A friend of mine read about my project here in this blog and related to a startup he got to know in this year Lisbon Challenge. The Lisbon Challenge is a acceleration program for startups that is held every year in Lisbon, Portugal. For more information in the program follow the link

http://www.lisbon-challenge.com/

The Videobserver is a platform that joins 4 important features in the statistical analysis of sports, video editing, scouting, easy of sharing information and real time applications. The software has not any computer vision feature and needs an operator in order to get information, I believe it’s important to comment that the developers of Videobserver have worked with computer vision together with sports but decided not to join that with their project, either as a concept or some other kind of decision.

https://www.videobserver.com/

The developers addressed a problem most people face, differently than others, amount of information available, instead of creating a tool able of detecting every possible scouting data, they have opted to create a simple interface, where the user can choose what information is important in each case. With the information edited in each case, the software also extrapolate other data.

Another interesting feature is the user interface, the developers gave extreme attention to that and the easy of use. The video editing can be done in 3 clicks and all information generated can be easily shared not only with other members of the team, but also with the players, in custom reports.

As I discussed in previous posts, the computer vision technology is still really expensive, considering that, the Videobserver can be a viable alternative where there is not a lot of money, that is show by the great amount of teams using it in Brasil and Portugal already!

During my conversation with one of the partners of Videobserver, he showed me a technique developed by the CVLAB in the École Polytechnique Federale de Lausanne that improves the results of tracking of players, even compared to kalman filtering. I have been trying to understand those techniques for the past month, and I believe now am able to write something about and even compare then a little. For the next post I will present the results of the search developed at EPFL and will proceed to a step-by-step of how to create a program in C++ and MATLAB that follows that procedure.

If you have any question of comment, do fell free to comment bellow!
Always a great pleasure to have readers.

Igor Hueb de Castro

State of the Art – Prozone

Continuing with my posts about the state of the art in computer vision applied to sports, today I will write about Prozone.

It is impossible to write about sports vision without writing about Prozone, nowadays it is the leading provider of such systems, working together with leagues sports broadcasters and teams to deliver not only bulks of information but also expert analysis on all information acquired.

Prozone became the leader in market after a fusion with the french Amisco, joining their products, they were able to provide a more complete system for everyone. 

There are eleven products that are sold by then, I will talk about some of then. 

PROZONE3/AMISCO PRO

PROZONE3/AMISCO PRO is football’s flagship performance analysis platform. Offering unique technical, tactical and physical data from multiple in-stadium cameras, PROZONE3/AMISCO PRO enables comprehensive post-match analysis and player tracking.

From what I could gather, this system utilizes 8 cameras that are fixed at the stadium, to track position of the ball and the players. All the information is collected and analysed so that after the game it can be presented to the team. 

This system is considered by everyone I have talked to, the best in tracking everything in the field, and also capable of solving almost every occlusion problem. The only comment that can be made is that the system needs to be installed in every stadium and teams must agree to some degree of collaboration in order to also receive information about others.

MATCHVIEWER/VIDEOPRO

Developed for those who require analysis at games where a PROZONE3/AMISCO PRO installation is not available, MATCHVIEWER/VIDEOPRO is used for reflection and preparation at all levels from academy to first team.

Regarding the problem presented above, Prozone developed this system, that uses video from tv transmission to gather information similar to the PROZONE3. Apparently, this system can not provide as much information as the one above, that is clear, as it only uses the video from one camera and that can not cover the hole field at any time.

For a team that want to have a complete analysis of its matches, where not every other team in the league utilizes PROZONE3, contracting both PROZONE3 and MATCHVIEWER is the best option.

OTHERS

There are other systems developed by Prozone, most of them just add some other functionality or integrate both that are described above, making then easier to apply in television, covering the hole field or even turning the system in a referee companion, like the goal line technology used by FIFA in the 2014 World Cup in Brazil.

Concluding, Prozone brings a lot o innovation to the field, and are the leading developers of new solutions, that integrate seamlessly in its actual plataforms. 

In another note, the facebook page of Prozone Sports (Prozone) frequently bring statistical analysis on important football matches. It is still possible to see their analysis in the finals of the World Cup.

Thank you for visiting, if you have any comments, of other information about Prozone, please write bellow so I can update this post!

Igor Hueb de Castro

State of the Art – STATS

In the last post, I wrote about my idea and some of its aspects, at first glance for someone that don’t know a lot about the subject it may seem extremely new, but for some years now, there have been technology that cover most aspects, in the following posts I will try to explain and differentiate most of then.

Unfortunately, there are not a lot of information online for most of the systems that are sold nowadays, so I will post what I gathered reading here and there and if anyone of you know any other information, please comment below and so I can update it!

STATS – SportVU

http://www.stats.com/sportvu/sportvu.asp

STATS provides a system that focus on delivering bulks of data to different areas in sports, specially for team and broadcasters.

Right now the SportVU is focused in basketball and soccer.

From their site:

Utilizing a sophisticated technology software algorithm to collect the X/Y positioning data of the ball and participants (players and referees) within the playing field in real-time, STATS analyzes the accumulated data streams and compiles meaningful information and insights.

The  system is based on 3 HD cameras fixed and in the stadium, together with mobile interaction through apps.

The amount of information delivered is enormous! Not only simple stats like ball possession, turnovers, speed of players and ball, but the system also infer some interesting information, like defensive/offensive formation, tendencies of passing and marking.

A complete description of the features in:

http://www.stats.com/sportvu/football_data.asp

Considering the sheer amount of information, the STATS technology, is an amazing option in the market right now.

Price: I have no information o prices.

Now, relating a little to my own project, considering the amount of information delivered by the SportVU, I really don’t see how it can be improved, but one concern for all coaches I have been talking to is, how can you really know the true relation about, for example, shot efficiency and wins?

Sometimes I fell that a really big amount of data is as bad as no data at all, there are other people in the industry that believe that only the vital and related information should be used. I plan to write more about that as soon as I finish writing about all the state of the art technologies in the market.

Thank you for spending your time here, feel free to make any suggestions critics or comments!

Igor Hueb de Castro

1. Introduction

Welcome to Embedded Sports Vision!

As the name suggests, this is a blog about applications of computer vision in sports situations together with an embedded system. More than a general view of the area, I will publish here everything I have been doing in a project.

The project still don’t have a name, but it consists of the creation of an embedded system with computer vision software, capable of tracking players and ball movement in a soccer match, and using that information to infer some data. The project will be divided in three parts, the embedded system, which will cover all de hardware used, and also most of the web interface; the computer vision program, that will transform the video captured by the hardware into a table of position of players and ball for each frame; and the android application, that consists of an easy way to display information in real time for coaches and sports fans.

The image below shows each area with the core functions.

fluxo

The conclusion deadline of this project is in June of 2015, as that is when I graduate, and throughout this year I will try to write at least one post per week, not only with my progress, but also with interesting information regarding all the subjects in the area.

In the next two week I will also try to write everyday as I have some free time at hand!

Stay tuned!

Igor Hueb de Castro