Football Players Tracking | YOLOv5 + ByteTRACK | Google Colab | step-by-step Tutorial

Поделиться
HTML-код
  • Опубликовано: 11 янв 2025

Комментарии • 140

  • @jaredpereira8487
    @jaredpereira8487 Год назад +4

    Hello! I saw your content on data is beautiful via Reddit. Thank you so much for all your hard work. You’ve inspired me to TRY and learn some of these tools! Wish me luck 🍀

    • @Roboflow
      @Roboflow  Год назад +1

      This is awesome complement. Thanks for sharing that. 🙏🏻 You on the other hand inspired me to push forward and publish more.

  • @adityasprojects7126
    @adityasprojects7126 2 года назад +8

    Can we build someting with kalman filters, eg: where the player is taking the ball, where he would shoot it, how players would move with respect to ball's position etc. This would be a great analytics to any team to get good insights. It could also summarize player's general behaviour in many situations

    • @roboSkalskiP
      @roboSkalskiP 2 года назад +2

      Hi, it's Peter from video. Does it need to be with kalman filters? I personally feel that conversion to bird-eye-view (BEV) is the key to all those advanced analytics.

    • @adityasprojects7126
      @adityasprojects7126 2 года назад +1

      @@roboSkalskiP Ofcourse not. And to be honest I don't even know if we can use KF here. I had done couple of projects on my own wherein i track and predict ball's position in next few frames using KF. I thought we could use it here as well. And yea, we should be able to get some analytics from BEV. I'm just curious if such videos are even available. If yes, can actually do some like i stated earlier? That would really be awesome!!!

    • @roboSkalskiP
      @roboSkalskiP 2 года назад +2

      @@adityasprojects7126 I like challenges ;) but you are right it is super hard! for now I just have some ideas nothing more.

    • @74Gee
      @74Gee Год назад

      @@roboSkalskiP How about if the people were not footballers in a uniform but people in a crowd wearing random clothes. How should I go about re-detecting the same person based on their clothing attributes and vecctor, maybe some sort of color map with a decay since last seen would do it?

  • @muza886
    @muza886 2 года назад +2

    really impressive work , PETER Sir

    • @SkalskiP
      @SkalskiP 2 года назад +2

      Thank you very much! I needed a bit o motivation this morning :)

  • @alexandergrifith7786
    @alexandergrifith7786 2 года назад +2

    This is awesome!

  • @YongTang-rh4si
    @YongTang-rh4si 2 года назад +4

    This is awesome! I want to know whether having a tutorial about multi-cameras MOT?

    • @Roboflow
      @Roboflow  2 года назад +1

      This is actually a great idea! Let me add that to my TODO list.

    • @redabenallal4695
      @redabenallal4695 2 года назад

      @@Roboflow i am really interested too , it would be awesome

    • @anadianBaconator
      @anadianBaconator Год назад +1

      @@Roboflow I would be super interested too!

  • @liellplane145
    @liellplane145 2 года назад +3

    So cool and bless you for sharing

    • @roboSkalskiP
      @roboSkalskiP 2 года назад

      Oh! It's Peter here :) Thank you for such kind words!

  • @jonimatix
    @jonimatix Год назад +2

    Can you please show how you custom annotated the data set and trained the model ?

  • @paulpolizzi3421
    @paulpolizzi3421 Год назад +3

    Amazing, can this track touches, possession percentage?

    • @SkalskiP
      @SkalskiP Год назад

      Yup it is possible. If you want to be super precise then it is still long way to go. If you just want to have a estimation it is pretty much ready.

  • @JonasZaoui
    @JonasZaoui 11 месяцев назад

    Wonderful works thanks !
    It's possible to improve the tracking of the players ? Id is switching when player disappear and then appear on the frame, i have the same with all tracking methods

  • @LookItSnows
    @LookItSnows Год назад +2

    This is awesome! I'm trying to do something very similar with hockey games. In the end you mentioned that you managed to automatically classify the players by team by looking at their jersey colors. Can you upload or have you already uploaded a notebook somewhere showing how this is done? Thank you!

    • @Roboflow
      @Roboflow  Год назад +1

      Hi 👋! Yes, I shared the link to the Kaggle notebook as well as result examples here: github.com/roboflow/notebooks/discussions/113

  • @mehdijamey
    @mehdijamey 11 месяцев назад

    This is a great video and tutorial. Can you upload your custom model's weights for pytorch 2? current weights are not compatible.

  • @dhamaragudelo2684
    @dhamaragudelo2684 Год назад +1

    Hello, thanks for the video. I got the final video but I would like to know if I can access the x, y positions of each player. To the data what is used to generate the video. As it appears in the model that is in roboflow

    • @Roboflow
      @Roboflow  Год назад

      If you mean x, y coordinates on frame, than absolutely! You can access that data.

  • @aFuzyyy
    @aFuzyyy 11 месяцев назад

    Thank you so much, but the weights provided are not working fine, is there something wrong from my side or the weights are not compatible so i should train the model ?

  • @DhamarAgudeloMoreno
    @DhamarAgudeloMoreno Год назад

    Hello, thanks for your video. I am just entering the world of tracking and your video has helped me a lot. But I have a question, in the chapter YOLOv5 pre-trained COCO model inference to view the video you mention at minute 4:40 you mention that thanks to cinema you can view the results immediately. What is cinema? because I ran the lines of code and it prints this but I can't display the video.
    someone please help me

    • @Roboflow
      @Roboflow  Год назад

      Oh I just downloaded the video from Colab.

    • @DhamarAgudeloMoreno
      @DhamarAgudeloMoreno Год назад

      @@Roboflow Can you explain to me how you download the video from Colab? please

  • @rafael.gildin
    @rafael.gildin 9 месяцев назад

    Great video.
    Did you test the same process in yolo v8 object tracking? If so what was the output?

  • @cecijos
    @cecijos 2 года назад +2

    Great, thanks for sharing

  • @createdbyAnsigar
    @createdbyAnsigar Год назад +1

    Can we count the passes and change theplayer into 2D and also export the events into csv ?

  • @jongwukson273
    @jongwukson273 2 года назад +1

    great video. thanks so much

  • @hoctoancungkhoathu
    @hoctoancungkhoathu Год назад +1

    Thanks for your sharing ! I want to ask about the type of file that we use to store the annotations. Which one should I save ? (txt, coco json...)

    • @Roboflow
      @Roboflow  Год назад

      Hi 👋! I'm confused. Please help me to understand, what do you want to save? Tracking results? If so then I'd suggest CSV.

  • @ammararazzaq132
    @ammararazzaq132 2 года назад +1

    is it possible to build a goal keeper detector as well? will an object detector be able to differentiate goal keeper from rest of the players?

    • @SkalskiP
      @SkalskiP 2 года назад

      I'm sure it is! It is only question of providing anough examples. In my dataset there were some images with golies but not enough to do it reliably. But given the fact that referees are usually correctly detected, I'm sure we could do the same for golies.

  • @Raulvic
    @Raulvic 2 года назад +1

    Thank you for sharing!

    • @Roboflow
      @Roboflow  2 года назад +1

      Thanks for watching :)

  • @anishkuvelkar1876
    @anishkuvelkar1876 4 месяца назад

    hey , instead of numbers can u track them by analyzing their faces or jersey numbers ? if so how ?

  • @5-minutepython
    @5-minutepython 2 года назад +3

    Wow, what a wonderful project. But I think the ball tracking won't works well here. Because the balls are placed outside the field as well. Am i correct.

    • @Roboflow
      @Roboflow  2 года назад

      Ball tracking is indeed really complicated. And there are multiple reasons that contribute to it:
      - Extra balls outside football field - that can lead to multi ball detection. To prevent any accidental "ball possession, we discard all ball detections on frames where there are more than one.
      - When ball is being kicked by the goalkeeper it flights really high, and the flight path leads across the stands. Model don't know how to distinguish ball from all those heads.
      - There are occlusions, where player accidentally hide ball from camera.
      - Ball is relatively small, so IoU based trackers may miss it when it travels fast.

    • @5-minutepython
      @5-minutepython 2 года назад +1

      @@Roboflow yeah, it’s complicated. But i solved these issues after a long research🤗

    • @Roboflow
      @Roboflow  2 года назад

      @@5-minutepython congrats! This topic is super interesting and inspiring!

  • @trappedinme1883
    @trappedinme1883 Год назад +1

    Hello, I am completely new to computer vision have been spending the last week having a look, I am trying to get my head around the process, I modified this to use YoloV8, had some slight issues at start due to using a Macbook with an M1 Pro chip and the GPU not being accessible but sorted now, I am running the first stage to use the pre-trained COCO model, in the video you cut, I am about 6 hours in, was just wondering how long this should take roughly?
    Trying to create something that can be used by grassroots teams to record games as the current offering from Veo and Pixellot have gone way beyond the price of most clubs and keeps rising (nearly doubled in price within a year), think it would be really useful to help reduce violence towards ref whilst also hopefully catching and create memories of moments in matches, in an affordable way.

    • @sleepyshoes
      @sleepyshoes Год назад

      I'm attempting to do this same idea. Did you manage to get this working? Thank youn

  • @hedibendaoud4831
    @hedibendaoud4831 Год назад

    Great job!

  • @pareshkamble7888
    @pareshkamble7888 2 года назад +1

    Nice work.

  • @9876farhan
    @9876farhan 2 года назад +1

    wah great explanation. but one question, can this bytetrack use for a hand movement recognition like handsign?

    • @Roboflow
      @Roboflow  2 года назад

      ByteTRACK is a tracker it can track everything as long as you have a detector capable of detecting it. We have plenty of datasets that you could use to build such detectors at Roboflow Universe: universe.roboflow.com/search?q=handsign

  • @jasonjasonkim
    @jasonjasonkim Год назад

    Hi! I'm having trouble connecting to the GPU as a Mac user (specifically nvidia-tensorrt. Are you aware of methods to get around this problem?

  • @shreynalode60
    @shreynalode60 9 месяцев назад

    I have a doubt about how to calculate mota and motp of ByteTrack used

  • @temitopeibrahimamosa2885
    @temitopeibrahimamosa2885 2 года назад +3

    The kaggle dataset is not accessible... because no new entry is allow to the competition!
    please did anyone as the data and can share

    • @Roboflow
      @Roboflow  2 года назад

      Oh. Thanks for pointing that out. That whole competition looks like it is frozen. It should be ended like two months ago, but it looks like it is still on. Do you need the whole dataset or just some example videos?

    • @temitopeibrahimamosa2885
      @temitopeibrahimamosa2885 2 года назад +1

      @@Roboflow Thank you for your response.. some video is okay

    • @temitopeibrahimamosa2885
      @temitopeibrahimamosa2885 2 года назад +2

      I also want to ask, apart from the video did you inference the model with other video

    • @akashrakshit7842
      @akashrakshit7842 2 года назад +2

      @@Roboflow Yeah a few sample videos will be ok for now. Would be highly thankful if you can provide that.

    • @roboSkalskiP
      @roboSkalskiP 2 года назад +1

      @@akashrakshit7842 Hi! It is Peter from video. Let me just ask around in @Roboflow, we will try to help you ;) stay tuned

  • @omarfarooqahmad
    @omarfarooqahmad Год назад

    Hey Love your videos if i wanted to do jersey detection inside the players what approach would you recommend

    • @Roboflow
      @Roboflow  Год назад

      But only detection? Or you want to cluster those players somehow?

  • @henrydonahue9153
    @henrydonahue9153 Год назад +1

    awesome!! the line where you download the clips file is not working for me.

    • @Roboflow
      @Roboflow  Год назад

      Do you mean download from Kaggle? What is the error you see?

  • @linxuer
    @linxuer Год назад

    There is a data set in your kaggle that is already private, can you give me the data set? I can't run all your code on kaggle

  • @eranfeit
    @eranfeit Год назад

    Very good !!!

  • @avamaeva7999
    @avamaeva7999 Год назад +1

    Can you amend the code to work out how much each player has moved? eg Player X moved 3 kilometre, Player Y moved 4 kilometre..etc

    • @Roboflow
      @Roboflow  Год назад +1

      Hi. This is something I want to do, but to be honest it is a lot of work - probably a whole separate video. So it won’t happen to soon.

    • @automatedvideoingassistant6192
      @automatedvideoingassistant6192 Год назад

      @@Roboflow would you do this as a blog post if you do it? If so we will look out for it as this would be very interesting and exciting.

  • @silakanveli
    @silakanveli 2 года назад +1

    Great work! How fast is the inference fps for whole loop?

    • @Roboflow
      @Roboflow  2 года назад +1

      It is around 3 fps. But we use 2 heavy models on quite weak GPU. It is quite possible to bring it up to 15-20 fps :)

  • @vc1351
    @vc1351 Год назад

    Hello! Your video truly is awesome! Do you know some courses (online or not) in order to get into the field of Image detection/Object Tracking ? Thanks

    • @Roboflow
      @Roboflow  Год назад

      We have this curated playlist: ruclips.net/p/PLZCA39VpuaZajiCtgDDwU8ghchtqx347R
      Hope it helps!

  • @mohamadghaithalzin9318
    @mohamadghaithalzin9318 2 года назад +2

    Is it possible to use the model on an Android app using Java or Kotlin?

    • @SkalskiP
      @SkalskiP 2 года назад +1

      Short answare is yes, but it would be really complicated. How about running that on backend and streaming result to app?

    • @mohamadghaithalzin9318
      @mohamadghaithalzin9318 2 года назад +1

      @@SkalskiP
      Well, Do you mean sth like triggering a Lambda function of Python code on AWS that receives image data and returns the result of the model?

    • @SkalskiP
      @SkalskiP 2 года назад +1

      @@mohamadghaithalzin9318 for example, if you don't need real time processing

    • @mohamadghaithalzin9318
      @mohamadghaithalzin9318 2 года назад +1

      @@SkalskiP
      Indeed I do need real-time processing!

    • @SkalskiP
      @SkalskiP 2 года назад +1

      @@mohamadghaithalzin9318 hm... I'm not sure about the performance, but you can definitely convert detector from pytorch to tensorflow light and run it on android device. Tracking can be a problem. I'm not really familiar with any implementation in Java or Kotlin :/

  • @createdbyAnsigar
    @createdbyAnsigar Год назад

    Can you share your chanel for twich

  • @Premiercoaching
    @Premiercoaching 2 года назад +1

    This is brilliant. I've been looking for something like this. Can I track players from my own full game footage?

    • @Roboflow
      @Roboflow  2 года назад

      I think if camera angle will be similar it should work. If you want to confirm, pick one frame from your video, and drop it here: universe.roboflow.com/roboflow-jvuqo/football-players-detection-3zvbc/model/2 It's slightly less powerful version of my model.

    • @Premiercoaching
      @Premiercoaching 2 года назад +1

      @@Roboflow Thanks for the reply. I dropped an image in. What am I looking for?

    • @Premiercoaching
      @Premiercoaching 2 года назад

      I also uploaded the video. The image/footage is from a drone so it is a similar camera angle.

    • @Roboflow
      @Roboflow  2 года назад

      ​@@Premiercoaching It should basically be a detection test. Notice if model:
      - detected ball
      - detected all football players
      - distinguished between players and referees
      - not detected any additional people that shouldn't be detected
      If answers for all of those questions are positive than you should be able to successfully use code in Google Colab to track players on your own football game footage.

    • @Premiercoaching
      @Premiercoaching 2 года назад

      @@Roboflow ah, OK. It has not detected all players, the ball and referee. It has detected most players and some people at the side of the pitch.

  • @MassimoArteconi
    @MassimoArteconi Год назад +1

    If we change the videa with a different one what are the point of attentions?

    • @Roboflow
      @Roboflow  Год назад +1

      - First of all, make sure that the videos that you plan to use are without any cut scenes. We trained our model on this dataset: app.roboflow.com/roboflow-jvuqo/football-players-detection-3zvbc/4 so the camera perspective should be similar.
      - We can detect referees and goalkeepers so make sure you test and validate if the model can detect those. Depending on the league model may have problems If, for example, refs are wearing a different color of shirts.
      - Make sure to run detection with as high inference resolution as possible.

    • @Roboflow
      @Roboflow  Год назад

      If you'd like to discuss more, feel free to start a thread here: github.com/roboflow/notebooks/discussions/categories/q-a

    • @MassimoArteconi
      @MassimoArteconi Год назад +1

      @@Roboflow done :) lot of questions come to my mind

    • @Roboflow
      @Roboflow  Год назад

      @@MassimoArteconi great! Let's have a chat there :)

  • @gbo10001
    @gbo10001 Год назад

    is there some support team that i can consult with for solving my use case?

    • @Roboflow
      @Roboflow  Год назад

      I wouldn't call that support team. But you can post your question here: github.com/roboflow/notebooks/discussions/categories/q-a and we will try to help you :)

  • @adamabubaker4784
    @adamabubaker4784 2 года назад +3

    facinating

    • @Roboflow
      @Roboflow  2 года назад

      We are supper happy you like it :)

  • @akashrakshit7842
    @akashrakshit7842 2 года назад

    Not being able to download the kaggle dataset at the moment! Will that be only possible after the competition results?

    • @roboSkalskiP
      @roboSkalskiP 2 года назад +1

      Hi! It is Peter from the video. Few other people in comments have the same problem. I could access data because I was participating in the competition. I'm talking to people inside Roboflow, we will try to host part of that dataset for you to use.

    • @roboSkalskiP
      @roboSkalskiP 2 года назад +2

      Hi! You should find zip with 200 clips here: drive.google.com/file/d/1khi9E-uC6nfmOn-Vqhh1SYiTsynK7lUy/view?usp=sharing

    • @akashrakshit7842
      @akashrakshit7842 2 года назад +1

      @@roboSkalskiP thanks a ton Piotr. ❤ You are doing an amazing work.

    • @roboSkalskiP
      @roboSkalskiP 2 года назад

      @@akashrakshit7842 thank you very much :) I'm really happy you like it!

  • @ranamohtady2658
    @ranamohtady2658 Год назад

    How to get the api of this github code

  • @khadijakhaldi6468
    @khadijakhaldi6468 Год назад

    can we compute the speed of the players based on the video ?

    • @axaxnaji5368
      @axaxnaji5368 Год назад

      I think it's doable. However pitch size vary...

  • @smartfatorynumberone2760
    @smartfatorynumberone2760 2 года назад +1

    The important thing is the detector

    • @Roboflow
      @Roboflow  2 года назад

      Exactly! Without training the model on custom dataset the result wouldn't be as good.

  • @mahmoudfarid1288
    @mahmoudfarid1288 2 года назад

    Can that be done with yolov7?

    • @Roboflow
      @Roboflow  2 года назад +1

      Hi! Nope, with YOLOv5

  • @NEZERSEY
    @NEZERSEY 2 года назад

    how can yolov5 inference be remodified

    • @SkalskiP
      @SkalskiP 2 года назад

      Hi it is Peter from the video. Could you be a bit more precise? I'm afraid I don't understand.

  • @awezsheikh8962
    @awezsheikh8962 6 месяцев назад

    Cant load kagle dataset any another way

    • @Roboflow
      @Roboflow  6 месяцев назад

      What’s the problem with Kaggle?

    • @awezsheikh8962
      @awezsheikh8962 6 месяцев назад

      ​@@Roboflow it's showing out of date can't use the loading dataset command.
      Which is
      !kaggle competition files -c dfl-bundeslinga-data-shootout | grep clips | head-10
      I checked in kaggle it showing no dataset available for dfl- Bundesliga

  • @combustion2479
    @combustion2479 2 года назад

    I have no idea why my questions have been deleted.

    • @Roboflow
      @Roboflow  2 года назад

      Did RUclips deleted your comment? We haven't done that.

    • @combustion2479
      @combustion2479 2 года назад

      @@Roboflow I don't know. Btw, if it is public, I would like to ask about some details of the custom model training settings. Many thanks!

    • @Roboflow
      @Roboflow  2 года назад

      @@combustion2479 Sure thing! If possible create issue or discussion topic on github.com/roboflow-ai/notebooks It is much easier to have this type of conversation there.

  • @jacobjonm0511
    @jacobjonm0511 Год назад

    These tutorials are only good for making videos on youtube using and simulated data. Once you deploy them in real world football then you see they are hopeless.

    • @Roboflow
      @Roboflow  Год назад +1

      Hi Jacob 👋🏻 This data is not simulated. It is coming straight from Bundesliga games.

  • @ifyugwumba8120
    @ifyugwumba8120 Год назад +1

    Thank you very much for this beautiful content I got hold of your content from LinkedIn.I would like to ask if someone wants to be like you what path would one take I guess you are an ML engineer 😊 Thank you

    • @Roboflow
      @Roboflow  Год назад +1

      Oh! Thanks a lot 🙏🏻 I aus great to start weekend reading something like this. It is quite long story. But on Monday I’m point to be guest of a podcast and we will talk among other things the path I took to be here. If you follow me on LI you will definitely see me posting about that next week.

    • @ifyugwumba8120
      @ifyugwumba8120 Год назад

      @Roboflow Alright thank you so much for your response and time looking forward to your podcast am all down to listen

    • @Roboflow
      @Roboflow  Год назад

      @@ifyugwumba8120 not mine :) I’ll just be guest ;)

  • @zackshainsky2637
    @zackshainsky2637 2 года назад +3

    This is awesome!