YOLOv8: How to Train Objection Model with Custom Dataset

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

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

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

    Join My AI Career Program
    www.nicolai-nielsen.com/aicareer
    Enroll in My School and Technical Courses
    www.nicos-school.com

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

      how do we want to make detection prediction classs 12:07

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

      @@faisalhazry i show that in another video on my Channel with yolov8 class

    • @dakaradakaradakara699
      @dakaradakaradakara699 4 месяца назад +1

      Sir please make a project tutorial like this, but with classifications custom dataset on roboflow.

  • @harish3828
    @harish3828 Год назад +9

    one mistake or update
    in the yolo training line
    data={dataset.location} wont work so try
    source="dataset location"

  • @neeraj.kumar.1
    @neeraj.kumar.1 Год назад +9

    Bro pls consider only one window of yourself because many information is getting hide.

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

    you are always doing the best congratulations!!

  • @HarsimranKaur-h2o
    @HarsimranKaur-h2o 8 месяцев назад +1

    Thankyou so much, Your video was short and simple and it helped me out a lot

    • @NicolaiAI
      @NicolaiAI  8 месяцев назад

      Glad it helped!

  • @ANiceGuy00
    @ANiceGuy00 2 месяца назад

    Interesting! Can you make a tutorial on trajectory prediction with OpenCV and/or other computer vision libraries?

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

    Hi, you mention around 14:26 that you exported or downloaded the model so that you could use it with the webcam, but you don't describe that process at all. How do you get the pt file with your custom-trained model from Google Collab?

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

      also still trying to figure out what happened there... solution?

    • @Luca-yt2bg
      @Luca-yt2bg Год назад

      i am in the same question

    • @Luca-yt2bg
      @Luca-yt2bg Год назад +1

      @@sevenplyy I FOUND

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

      @@Luca-yt2bg NICE! please tell me

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

      @@Luca-yt2bghow?

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

    This is really amazing. I really love your video. Kindly make a video on multiple video stiching and like making it live.

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

    It seems it does not like the reflectivity of the std cup at the end. Make sense, tricky case really, even for deepnet models. Thanks for the video, very cool nontheless. I like especially when you show stuff which do not work perfect on the webcam, that is interesting and genuine.

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

      Yeah for sure. Also the std cup was underrepresented in the dataset doe. I could have tuned some confidence score thresholds or added a tracker. It will make some false predictions when moving the camera around and when it runs with 75+ fps

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

    hello sir i followed your tutorial and it worked out great! Do you have a video on how to extract the coordinates of the bounding box so i can determine the centroid of the boxes?

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

      Thanks a lot for watching! Yeah I have a video where we implement it in a custom class

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

    Great video! Just wonder how to verify the evaluation results of mAP, Precision and recall in Roboflow using the results in Google colab?

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

    Thanks for the video! Will you be making a video on training a custom dataset for segmentation on Yolo v8?

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

      I already did! Check out the second latest video

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

      @@NicolaiAI I saw thank you! What I mean is using your own dataset containing your own images. Do you maybe have a suitable tool that I can use to draw the bounding polygons for segmentation? I have used LabelImg already, but it obv is not going to cut it for instance segmentation datasets.

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

      He has already made it!!! last video

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

      @@erikpetrosyan9662 that's my bad, I clearly didn't pay enough attention. Thanks

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

    thanks for the vid! can you make a video on how we can test our model for custom dataset (like a bunch of images on my local pc)?

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

      The first video I have about yolov8 I show how to use the command line for testing the Yolov8 models. I show with the webcam as the source but u can just throw in the path to the images or an image folder instead. Thanks for watching!

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

    Any idea on how to deploy this on a cloud server? How would you connect the cameras?

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

    Hi. I was actually looking for the deployment process and skipped to that chapter in your video, but it looks like only inference is being shown. Where and how is it being deployed? Using kubernetes? TF serving?

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

    Hello, I love your videos and was wondering if you could make a video that covers in depth training process and datapreprocessing (such as: data augmentation, hyperparameter tuning, evolve, data vizualization etc.)

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

      Hi thanks a lot for watching! I already have videos going over all those things in my deep learning playlist

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

      Data Preprocessing is the most asked thing in this field I experienced this as an intern. I would request you to take the data and normalize and convert them to to nparrary Or do some Preprocessing. Kindly make it from a granular level

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

    You videos are great ,I have been trying to count people at full screen or frames using yolov8 and with no success,what are the cods to do so I

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

    Thanks for the good video. I will follow it. Can i get the coordinates of the detection objects real time? I would like to use them as an input for another program.

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

    thanks for the video. how can i tackle a task of counting objects in a video with moving camera? specifically sea animals in a big pool so i need to scan all the pool and accumalte the numbers

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

      Thanks for watching! My tracking course with Yolov8 can exactly be used for that

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

      @@NicolaiAI t
      Does this course have support chat or something?

  • @AdityaKumar-lv5st
    @AdityaKumar-lv5st Год назад

    Where can I find the complete code for using the trained model for prediction? Its not completely visible in the tutorial video.

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

    At 5:58 the "!yolo task=detect mode=train model=yolov8m.pt data={dataset.location}/data.yaml epochs=30 imgsz=640" command is not appearing on the notebook I copied. Should I add it manually? Also the 2 commands afterwards (start with image(filename)) are missing also from the notebook. If I run the following command (!yolo task=detect..) it fails. The error is:
    Traceback (most recent call last):
    File "/usr/local/bin/yolo", line 8, in
    sys.exit(entrypoint())
    File "/usr/local/lib/python3.10/dist-packages/ultralytics/cfg/__init__.py", line 423, in entrypoint
    getattr(model, mode)(**overrides) # default args from model
    File "/usr/local/lib/python3.10/dist-packages/ultralytics/engine/model.py", line 372, in train
    self.trainer = trainer(overrides=overrides, _callbacks=self.callbacks)
    File "/usr/local/lib/python3.10/dist-packages/ultralytics/engine/trainer.py", line 127, in __init__
    raise RuntimeError(emojis(f"Dataset '{clean_url(self.args.data)}' error ❌ {e}")) from e
    RuntimeError: Dataset '/content/Loco1-1/data.yaml' error ❌
    Dataset '/content/Loco1-1/data.yaml' images not found ⚠, missing path '/content/Loco1-1/Loco1-1/valid/images'
    Note dataset download directory is '/content/datasets'. You can update this in '/root/.config/Ultralytics/settings.yaml'

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

      same problem with me here

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

      there a duplicate 'Loco1-1' here '/content/Loco1-1/Loco1-1/valid/images', you can delete the 'Loco1-1' in data.yaml train and val

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

      Hello, where you able to fix it?

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

      @@houdabekkourialami3581 No

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

    Superb informative! 🔥 May I ask for the Colab link? 🙏

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

      Thanks a lot! All the code is available on my GitHub

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

    can you provide the colab notebook

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

    Thanks for this. However, the last part of the video isn't really "deploying" the model anywhere - it is about using it locally.

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

      Yes u can deploy models locally

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

    Thanks a lot. In your code, line 5, how did you export and get the .pt file? I exported from roboflow as yolov8 but I don't get any pt file.
    thanks again :)

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

      U need to train the model as i do in this video. I then show how to download the model

  • @houdabekkourialami3581
    @houdabekkourialami3581 11 месяцев назад +1

    Hello! I'm having trouble while trying to fix the epochs, i get an error that there are no images in the dataset although they are in fact existing in all of the train validation and test files. How can I fix ?

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

      There are some problems with the data.yml file. Replace the paths to the correct ones in there

    • @houdabekkourialami3581
      @houdabekkourialami3581 10 месяцев назад

      Thank you so much. However I hvae another problem. When I run the vscode script I do get the results running in the terminal but the webcam isn't displayed. My webcam is activated and it does show up when I try functions like cv2.imshow()..

    • @houdabekkourialami3581
      @houdabekkourialami3581 10 месяцев назад

      Never mind it works fine now. I had to update my environement.

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

    I get errors when passing to Install YOLO v8: ValueError: Invalid 'mode='. Valid modes are ('train', 'val', 'predict', 'export', 'track', 'benchmark').

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

    awesome vidoes

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

      Thanks a lot! Really appreciate the support

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

    How did you get the results to save to 'runs/detect/predict/'? I have been struggling with this feat every time.

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

      It should do that automatically if u run the predict command

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

      you have to add the argument save=True

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

    @NicolaiAI thanks for the video! can I see the python code that you used in 14:25?

  • @ricardovaleriocarera436
    @ricardovaleriocarera436 Месяц назад

    When i do the predictions this way my gpu memory fills up quite fast is there a way to prevent this

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

    thank you very much

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

      Thanks for watching! Glad that it could help u

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

    I have trained how you do in the video but do not see how to export? can you help

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

    Where can I find the Colab scripts used in this RUclips video? Thanks.

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

      Thansk for watching! Think i deleted it when i updated the description. It is not added again. colab.research.google.com/drive/1q0GqWbYjACs9uVTjhsQfVQkfF0hhLHsq?usp=sharing

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

      @@NicolaiAI Thank you.

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

    Can you please do a tutorial video detecting potholes and crack using raspberry pi

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

    may I ask sir, what code ediitor your are using?

  • @8PassCharlie1
    @8PassCharlie1 Год назад

    hey can you tell is there anything else after import detection in line 2 of the code?

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

    hi, what webcam do you use in your projects

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

      I’m just using a cheap budget webcam

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

    **UPDATE**
    !yolo checks
    change content in -> data.yaml -> to
    train: ../train/images
    val: ../valid/images
    Image(filename=f'/content/runs/detect/train7/confusion_matrix.png', width=600)

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

    I have some problem with my virtual environment
    I installed all the required files and when I try to import YOLO from ultralytics for example from jupyter notepad using VScode, the import gets stuck and looks like it will never finish
    Maybe some of you have had a similar problem or know what is wrong with my environment?

  • @SaurabhSingh-mu5td
    @SaurabhSingh-mu5td Год назад

    Hii, very good work but how can i convert output in audio form so that it can be used by blind person

  • @michaelaaron2134
    @michaelaaron2134 7 месяцев назад

    I’m constantly getting “FileNotFoundError”when training please what can i do

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

    hey, Can you provide me a script on how to deploy yolov8 model for intel Realsense Camera. Thanks in Advance! Btw your tutorials are very helpful. Keep up with the work!!

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

      Thanks a lot man! I already have a video where we implement a custom class with the yolo model and run inference on webcam then u will just have to swap the camera

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

    my problem is stoping the session in kaggle or google colab and my volum dataset is 4005 image can you help me pleas Because I have my graduation thesis and I don't have much time

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

    how can I export the mode and get the path to it 14:30

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

    Hi, I was struggling with the python script to use it , so, thank you very much for uploading this tutorial! 😄
    But, I still have one question, how can we deploy it using flask or some other framework?

    • @AdityaKumar-lv5st
      @AdityaKumar-lv5st Год назад

      HI, could you post the link to the python script for using the trained model for prediction. The complete code is not visible in video

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

    how can tunning hyperparameters for yolov8?

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

    How do i deploy it to mobile devices using flutter?

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

    permission to learn and download dataset in roboflow sir. thank you

  • @every-thing-is-ai
    @every-thing-is-ai Год назад

    tell me how to deploy yolov8 model on webcamp in colab

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

    sir if i place rtsp link instead of webcam source 0 , it freezes . Any solution for this sir.. Thank u

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

    Hello Brother I want the output results in json format do help me

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

      If u Watch my tracking video u Can see how to extract the results

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

      @@NicolaiAI Thanks for the reply brother

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

      @@joart333 of course!

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

    Hi, Where is the code at 14:25 ?

  • @syariffortask
    @syariffortask 8 месяцев назад

    I using gtx1650,and why always using cpu intel core i5 gen 10 ram 16 gb process in my detection?how to optimize?
    Anybody can explain?

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

    im getting error while training the model

  • @muhammadasil9374
    @muhammadasil9374 6 месяцев назад +1

    @NicolaiAI Sir, please make a video on: how many sample or images of an object for training and then implementing, epoches, batch confidence value for achive better result. #nicolainielsen #nicolaiaI

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

      Thanks for the tip, will put that on my list of next videos to create. :-)

    • @muhammadasil9374
      @muhammadasil9374 6 месяцев назад +1

      @@NicolaiAI thanks bro keep it up

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

      @muhammadasil9374 thanks bro!👊

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

    For users who are unable to run the training process, be assured to change the data.yaml from the yolk file downloaded in the Collab. Go into the code, on the most bottom line. Change the file directory to ../xxxx/xxxx