Thank you for your tutorials. They are very practical for me as I'm new to using AI models. I'd like to know if you've already made videos, or if you can make a video, on how to create models from scratch, especially techniques to achieve a good model that can capture the information we want. Let me give you an example: I want to recognize whether the bottle in my photo is a 2L Coca-Cola, 1L, or 600ml. Since they have very similar shapes and labels, pre-trained models like ResNet or others confuse them. If I create the model from scratch, I get worse performance. So I wonder, how do I push my model to focus on increasingly finer details to recognize the difference between these products?
In the mentioned scenario, you can work to get the size of the bottle. First detect the bottles using object detection model and then check the size of each bottle
The number of epochs needed for good results in object detection can vary widely based on several factors like for larger and more complex datasets needs more epochs. But there are some models which converge faster than others so in this case less epochs will also give you good results. Also, well-tuned learning rate can influence how quickly a model learns. Generally, many object detection models may start to show good results between 50 to 200 epochs.
@@CodeWithAarohi thx, i have just run your video training with the 20.000+ images and I noticed that after 80 epocs no major improvements have been donne. I did the same on hte 40.000+ dataset and I have seen the same.
I followed your video until 22:07 to test the image, there is no detections for the image. The test image was copied from the training image. What shall I do?
This tutorial is tested on PC (64GB RAM, NVidia RTX 3090 24GB vRAM) but you can run AI programs (except LLMs) on any Laptop or PC which have minimum 8GB RAM and Nvidia's GPU with atleast 6GB vRAM. Processing speed will be slow as per the model you are testing but it will work.
Try this: import cv2 from ultralytics import YOLO # Load the YOLO model model = YOLO("yolo11n.pt") # Open the video file video_path = "provide the path of live feed" cap = cv2.VideoCapture(video_path) # Loop through the video frames while cap.isOpened(): # Read a frame from the video success, frame = cap.read() if success: # Run YOLO inference on the frame results = model(frame) # Visualize the results on the frame annotated_frame = results[0].plot() # Display the annotated frame cv2.imshow("YOLO Inference", annotated_frame) # Break the loop if 'q' is pressed if cv2.waitKey(1) & 0xFF == ord("q"): break else: # Break the loop if the end of the video is reached break # Release the video capture object and close the display window cap.release() cv2.destroyAllWindows()
from ultralytics import YOLO model = YOLO('yolov8.pt') for param in model.model.backbone.parameters(): param.requires_grad = False # Freeze backbone layers # If you want to freeze specific layers, you can do something like this: for name, param in model.named_parameters(): if "some_layer_name" in name: param.requires_grad = False # Replace with your specific layer names
Copy move forgery detection in vedio using machine learning Use model: yolo Data set casia Please mam tell me how much time you upload vedio on above topic
Can we used semi-supervised model to train yolo like you do on custom dataset ? If yes, can you explain or do a video on this topic? Thanks a lot for your videos !
Hi, have u tried to export model to onnx format, why its size is large best.pt = 45.2Mb, but my onnx model = 87.Mb.... I set format='onnx', dynamic=True, half=True, device=0(GPU), int8=True
I have done the exact same steps but after training I used results=model.val(data='testData.yaml', split='test') code to see the metrics of model on test data set. Is that correct use ?
Thanks sister, you nailed it 🔥 . I wanna know that can we use google colab for do this project? Because we don't need to have much gpu if we use google colab
Yes, You can use google colab. Code will be same. You only need to select the gpu from notebook settings of Colab and then just change the paths where ever required.
Hi, great video! I'm interested in learning how to export and run the YOLO11 model in TFLite format. Could you please share a tutorial or code snippet on this in your next video or as a comment? Thanks!
Hello ma'am, could you consider making a video demonstrating how to deploy Yolov11 on Jetson Nano? I watched all of your Jetson Nano videos, but I was unable to complete them because they involved the processing speed of the CPU and GPU. Your vids are terrific!
what if i have an intel GPU, train_results = model.train( data="C:/yolo/LicencePlateDataset/data.yaml", # path to dataset YAML epochs=10, # number of training epochs imgsz=640, # training image size device=0, # device to run on ) here it does not recognises device=0 as a GPU
Again. Worth watching your videos
Thank you so much 😀
Your channel is a gold mine. Thank you maam
I’m so glad you’re enjoying the content!
better and better a pleasure this tutorial
Thank you!
one of the best video on yolo model. thank you.
Glad it was helpful!
Can you make a little advance, like first detecting the number plate and then extracing text from it.?
thanks very clear, you are top teacher
Thank you!
I don't know how to thank you! , thanks a lot
You're welcome!
Hi, Amazing content right here! A video about evaluating the model and fine tuning would be amazing! Thanks again
Thanks, Noted!
Excellent work
Many thanks
Amazing video
Thanks!
Very well explained
Glad it was helpful!
genia un beso , desde argentina
Thanks!
Thanks a lot!!! 😇 Can I use this for obstacle detection like rocks and terrains ?
Yes you can!
Superb 👍👍👌👌👏👏
Thanks 🤗
Thank you for your tutorials. They are very practical for me as I'm new to using AI models. I'd like to know if you've already made videos, or if you can make a video, on how to create models from scratch, especially techniques to achieve a good model that can capture the information we want. Let me give you an example: I want to recognize whether the bottle in my photo is a 2L Coca-Cola, 1L, or 600ml. Since they have very similar shapes and labels, pre-trained models like ResNet or others confuse them. If I create the model from scratch, I get worse performance. So I wonder, how do I push my model to focus on increasingly finer details to recognize the difference between these products?
In the mentioned scenario, you can work to get the size of the bottle. First detect the bottles using object detection model and then check the size of each bottle
based on your experience how many epocs give good results so that more than that it is a waste of time/resources?
The number of epochs needed for good results in object detection can vary widely based on several factors like for larger and more complex datasets needs more epochs. But there are some models which converge faster than others so in this case less epochs will also give you good results.
Also, well-tuned learning rate can influence how quickly a model learns.
Generally, many object detection models may start to show good results between 50 to 200 epochs.
@@CodeWithAarohi thx, i have just run your video training with the 20.000+ images and I noticed that after 80 epocs no major improvements have been donne. I did the same on hte 40.000+ dataset and I have seen the same.
lovely vid ! cheers
Many thanks!
I trained v11 on rock paper scissor dataset, I am able to display the labeled image correctly but how can I get the predicted class ?
I followed your video until 22:07 to test the image, there is no detections for the image. The test image was copied from the training image. What shall I do?
If there are no detections then train your model for more epochs and also try to increase the data.
Thank you ❤
You're welcome 😊
Thank you. I following your AI videos regularly. May i know which laptop u using for ML and DL models. It will help to practice to learning.
This tutorial is tested on PC (64GB RAM, NVidia RTX 3090 24GB vRAM) but you can run AI programs (except LLMs) on any Laptop or PC which have minimum 8GB RAM and Nvidia's GPU with atleast 6GB vRAM. Processing speed will be slow as per the model you are testing but it will work.
Thank you🙏
Thank you Madam
Thank you for the video! I want to also watch a tutorial of implementing code that recognize objects in a live feed. Do you have a video of that?
Try this:
import cv2
from ultralytics import YOLO
# Load the YOLO model
model = YOLO("yolo11n.pt")
# Open the video file
video_path = "provide the path of live feed"
cap = cv2.VideoCapture(video_path)
# Loop through the video frames
while cap.isOpened():
# Read a frame from the video
success, frame = cap.read()
if success:
# Run YOLO inference on the frame
results = model(frame)
# Visualize the results on the frame
annotated_frame = results[0].plot()
# Display the annotated frame
cv2.imshow("YOLO Inference", annotated_frame)
# Break the loop if 'q' is pressed
if cv2.waitKey(1) & 0xFF == ord("q"):
break
else:
# Break the loop if the end of the video is reached
break
# Release the video capture object and close the display window
cap.release()
cv2.destroyAllWindows()
Yes plz ma'am
Thank you for the clear instructions. Is there a way in this to freeze certain layers while fine tuning or retraining?
from ultralytics import YOLO
model = YOLO('yolov8.pt')
for param in model.model.backbone.parameters():
param.requires_grad = False # Freeze backbone layers
# If you want to freeze specific layers, you can do something like this:
for name, param in model.named_parameters():
if "some_layer_name" in name:
param.requires_grad = False # Replace with your specific layer names
@@CodeWithAarohi Thank you so much!
Copy move forgery detection in vedio using machine learning
Use model: yolo
Data set casia
Please mam tell me how much time you upload vedio on above topic
Can we used semi-supervised model to train yolo like you do on custom dataset ? If yes, can you explain or do a video on this topic?
Thanks a lot for your videos !
Hi, have u tried to export model to onnx format, why its size is large best.pt = 45.2Mb, but my onnx model = 87.Mb.... I set format='onnx', dynamic=True, half=True, device=0(GPU), int8=True
Amazing
Thanks
I have done the exact same steps but after training I used results=model.val(data='testData.yaml', split='test') code to see the metrics of model on test data set. Is that correct use ?
docs.ultralytics.com/modes/val/
Thanks sister, you nailed it 🔥 . I wanna know that can we use google colab for do this project?
Because we don't need to have much gpu if we use google colab
Yes, You can use google colab. Code will be same. You only need to select the gpu from notebook settings of Colab and then just change the paths where ever required.
mam im doing the same but for fire detection, how to print 'fire detected' in output from live cam only if fire detected . is it possible
Yes, you can do that. You just need to print "fire detected" if fire is detected. You can use if condition.
Thank you Ma'am
Most welcome 😊
we can also use Roboflow to our own dataset and annotation?
Yes
Mam can you make a video on Conversational Image Recognition Chatbot. Please it would helpful..
I will try
Hi, great video! I'm interested in learning how to export and run the YOLO11 model in TFLite format. Could you please share a tutorial or code snippet on this in your next video or as a comment? Thanks!
I haven't tried that yet but topic noted. I will definitely make video on requested topic.
Hi I am getting ModuleNotFoundError: No module named 'ultralytics', though i have installed ultralytics on my env
Activate the env again and then try
Thank you. Can I implement YOLO11 on jetson TX2?
You need python 3.6 or higher
Hello ma'am, could you consider making a video demonstrating how to deploy Yolov11 on Jetson Nano? I watched all of your Jetson Nano videos, but I was unable to complete them because they involved the processing speed of the CPU and GPU. Your vids are terrific!
Sure, I will do a video soon!
Can you please make a video without using API
please can u make a video about adding an interface like gradio huggingface to this model
Noted!
@CodeWithAarohi not uploaded yet 🤔😔
Best Video 🥹
Thank you!
what if i have an intel GPU,
train_results = model.train(
data="C:/yolo/LicencePlateDataset/data.yaml", # path to dataset YAML
epochs=10, # number of training epochs
imgsz=640, # training image size
device=0, # device to run on
)
here it does not recognises device=0 as a GPU
I never worked with intel gpu. So no idea. Sorry