r/computervision
•
u/Selgorgulu
•
Sep 28 '26
•
1
Showcase Volleyball match analysis from a moving broadcast camera: RF-DETR + RTMPose + court homography + rules
Been working on a volleyball analysis pipeline, this is the current output on a full rally sequence.
The input is just the hall's automatic broadcast camera, so it pans and zooms. No fixed camera, no calibration.
Rough pipeline:
- Detection: RF-DETR Medium at 1280, fine-tuned on of my own labeled frames (ball + person). The ball is tiny (median ~22 px), which is why I stayed at 1280 instead of 640. Test AP50 is 0.92 for the ball, 0.97 for people.
- Camera motion: phase correlation between frames.
- Court: per-frame homography fitted to the white court lines, checked against the floor colour, so everything can be expressed in court metres.
- Ball: my own Kalman tracker with a gravity term, to bridge missed detections and catch bounces and hits.
- Pose: RTMPose on every frame, used for which hand/body part touched the ball and for the first referee's arm signals.
- Players: 6+6 tracks per team, plus referees and bench told apart by position (and shirt colour for the officials).
- Scoreboard: macOS Vision OCR on the broadcast graphic.
- On top of that, a rule layer (FIVB rules) that turns all of this into touches, blocks, rallies and points, and flags it when the scoreboard, the referee and the ball disagree.
It also estimates ball speed per hit (2D, so a lower bound), attack zone and direction, serve position and whistle-to-serve time, landing point in/out, and running distance (experimental).
Hardest parts so far:
- the ball leaving the top of the frame and the tracker jumping to something else
- referee signals: in this hall two staff stand behind the first referee and their boxes are taller than his (his legs are hidden by the stand), so picking "the tallest person on the stand" read the wrong arms
- every new hall = new floor colours, lines, lighting and camera angle
Yes it is all vibe coding with Claude
6
u/vade Sep 28 '26
Super nice - are you implementing with CoreML for ANE acceleration, or porting to Metal / MPS / MPS Graph (which can do ANE but has metal callbacks) or using the new CoreAI stuff?
Ive been doing a lot of computer vision with metal work and its so slept on, super fast / low latency on consumer if handled right. Apples out of the box Vision framework is nice for beginners but super slow / unoptimized for realtime stuff IMO.
3
u/Sionpai Sep 29 '26
How much of this is your input?
2
u/greengold7 Sep 28 '26
nice pipeline - moving broadcast cam is the hard mode, so a few things i'd watch:
what's your ball recall after occlusion, and how do you handle the zoom (focal changes invalidate a fixed homography)?
1
u/blobules Sep 29 '26
Looks good! What do you do for the 3d ball trajectory? It seems that a single view might not be enough, unless you also track the size if the ball.
1
u/prkash1704 Sep 29 '26
Any specific reason to select two models instead of using a single model pipeline? Like you could have used yolov26-pose.
1
u/LeKooks Sep 30 '26
Try a Single-stage pose estimation. You will win on latency if you only need human skeleton (try rfdetr-keypoints from roboflow or RTMO-lightweight in the rtmlib). I am not sure how good they are on Mac and for crowded scenes. This is human-focuses tho and you’d have to find a different option for the ball xD
1
u/NervousMedicine7115 Sep 29 '26
Willing to share the code and weights so I could try this on football broadcast video? Might not be useful for football material since the ball is much smaller in terms of pixels but curious to see how it would hold up.
Also have you considered using tracknet to do the detections?
1
u/doctor_blueberry Sep 29 '26
Looks cool! Nice to hear how you implemented each component. I also like the gameplay commentary overlays.
I have an open-source repo with several fitness demos that could be a helpful reference: https://github.com/jeremyipark/vision-demos
I'm using ViTPose so I was just curious if you had compared RTMPose and ViTPose.
1
u/AppMunchies Sep 30 '26
One of the best tracking demos I've seen recently - and there have been a few. There were a couple of weight lifting ones.
1
u/chicco83 Oct 27 '26
Hi, I need a similar tool to do scouting and game analysis. Is this a commercial project or an open one? I started developing something similar but I'm a lot behind what you reached.