As the dad of hockey player, what can we do if we don't know how to skate?! yes, we can write the code. As the name of loving, do whatever we can do for kids.
The final object is to create a video analysis system automatically which will use deep learning to analysis the video, tracing all player's position/movement and collect the athlete data.
However, a thousand miles begins with a single step. The first step of today is to resolve the fundamental challenge - map the rink from video image
to organized rink image.
The image transformer is very straightforward as the first version. OpenCV api provided 2 different ways to resolve it:
1. getPerspectiveTransform : support only 4 points mapping
2.findHomography: support at least 4 points mapping.
I wrote a quick code to help mark the key points from original image:
and we generated the image with key point marked
the python code could be simple as well
Make sure each of point is mapped to organized rink image correctly.
and finally, we will get the normalized the hockey rink which could be used for further research.
For livebarn panoramic view, the normalized image will be like following the step above:
The final object is to create a video analysis system automatically which will use deep learning to analysis the video, tracing all player's position/movement and collect the athlete data.
However, a thousand miles begins with a single step. The first step of today is to resolve the fundamental challenge - map the rink from video image
to organized rink image.
The image transformer is very straightforward as the first version. OpenCV api provided 2 different ways to resolve it:
1. getPerspectiveTransform : support only 4 points mapping
2.findHomography: support at least 4 points mapping.
I wrote a quick code to help mark the key points from original image:
and we generated the image with key point marked
the python code could be simple as well
Make sure each of point is mapped to organized rink image correctly.
and finally, we will get the normalized the hockey rink which could be used for further research.
Comments
Post a Comment