5

enter image description here

enter image description here

I have a question from school project. So we are given the task of tracking the volleyball from a given beach volleyball match video in mov format. The task is to track the ball and output the whole volleyball court in birds eye view, and also to draw the ball movement.

currently, Im still doing the ball tracking. However, I do not know how to do it exactly. I have thought of doing it in this way:

  1. get the 4 corners of the volleyball court using Harris Corner detectors
  2. use the 4 corners to find homography between different frames
  3. then remove background and player
  4. finally can track ball???

Is my thought process correct?

And I have tried to detect 4 corners using the harrisCorner detector. But it does not get the 4 corners. Any one has any suggestions? Thank you

leo277
  • 433
  • 2
  • 15
  • That's basically all wrong. 1) Harris corners are not what you think. Try instead to find the biggest rectangle. Should be easy enough. 2) Is the camera moving? If yes, good luck ;D. If not, you don't need to do this between frames, but just to know the coordinates in the bird eye view. 3) Players are non-static. You can't remove them with background subtraction. 4) First detect the ball, and then track. Actually it would be easier to just detect the ball each time and interpolate among missing frames. After all you just have one ball – Miki Oct 26 '16 at 14:16
  • You can possibly train a haarcascade for detecting the location of ball in every frame. Of course there will be some challenging cases, such as ball not being detected in some frames, or ball getting occluded by players, ball being hit out of frame. This can be addressed by having a good tracking technique. Try particle filter - it can recover well from short lived occlusion/misdetection. Here is a good demo on how particle filter works : http://seevisionc.blogspot.co.uk/2016/08/particles-explained-using-gifs.html – masad Oct 26 '16 at 23:33
  • Also if you could, please show us an image ( or maybe a sequence from the video)? – masad Oct 26 '16 at 23:35
  • the camera is moving. and sometimes i cant even see all the corners of the court.and the court is more like a trapesium than a rectangle. – leo277 Oct 27 '16 at 03:21
  • because the camera is moving, i cant see the full court throughtout the video. that is why i need to do a homography between frames so that i can stitch all frames to form the whole court. then i remove the background and players, so that i only have ball left to track. – leo277 Oct 27 '16 at 03:26
  • and we are not supposed to use particle filters, we can only use homography, edge detection, background removal, and simple techniques, and we cannot use most opencv functions, so i have to write homography myself :( – leo277 Oct 27 '16 at 03:28

0 Answers0