News for hackers. Stuff that matters.
Re:Show HN: Automatic Baseball Pitching Motion and Trajector... by kitd on Sunday January 03, 2021 @02:47PM (#25624542)
Apologies if this is a noob question, but I wonder how easy it would be to adapt this to other sports, eg cricket. Is the model specific to baseball, or can it be used for any ball-tracking?
Re:Show HN: Automatic Baseball Pitching Motion and Trajector... by chony on Sunday January 03, 2021 @02:55PM (#25624626)
Thanks for asking! This is not a noob question.

I would say that the similar workflow could be applied to any ball-related sports. The object detection and the tracking algorithm is basically the same. Then, you could add any sport-specific feature!

For example, I have used a similar method to build AI Basketball Analysis.

https://github.com/chonyy/AI-basketball-analysis

Re:Show HN: Automatic Baseball Pitching Motion and Trajector... by barnstack on Monday January 04, 2021 @05:09AM (#25629445)
Great point! Looks so much clearer than the early days of HawkEye as well
Re:Show HN: Automatic Baseball Pitching Motion and Trajector... by yanngagnon on Sunday January 03, 2021 @09:20PM (#25627324)
You may be interested in what Trajekt Sports are building.

https://trajektsports.com/

Re:Show HN: Automatic Baseball Pitching Motion and Trajector... by chony on Monday January 04, 2021 @04:06AM (#25629065)
Thanks, will definitely check it out!
Re:Show HN: Automatic Baseball Pitching Motion and Trajector... by GRVYDEV on Monday January 04, 2021 @01:29AM (#25628391)
Okay now this is awesome! Great work!
Re:Show HN: Automatic Baseball Pitching Motion and Trajector... by chony on Monday January 04, 2021 @04:02AM (#25629044)
I'm glad that you like it! Thanks a lot!
Re:Show HN: Automatic Baseball Pitching Motion and Trajector... by _31 on Monday January 04, 2021 @02:18AM (#25628574)
This looks great! How much data (clips/pitches) did you train your model on?
Re:Show HN: Automatic Baseball Pitching Motion and Trajector... by chony on Monday January 04, 2021 @04:05AM (#25629063)
Thanks for asking! The only model I used in this project is the YOLOv4 object detection model to detect the ball in each frame. I collected about 200 images to train it.

For the other parts like the tracking and the overlay timing, I programmed it by myself.

I implemented SORT algorithm for tracking the ball and some programming logic to capture the overlay timing from each clip.