Hey brother. great work. I just wanted to ask you how did you seperate the used zone and the unused zone for your detection; and is it possible to specifiy a crop in the middle for example, and that crop is only where the object detection model works.
its depends on your object detection model. In this case i used pretrained model of yolov5 which only has some popular types of vehicles. You can train a new model yourself on a vehicles dataset for more types
its not so hard. Just add some lines of code that specify left/right cars at the database part. See how the data looks like after being uploaded to database at my github link in the description. Btw, it's my homework excersise so i haven't refractor the code yet, so it''ll be a little bit hard to read and understand the code but basically the main file is the detect.py in yolov5 repo with some modifications
i am getting this error: kindly help for the same from utils.datasets import exif_transpose, letterbox ModuleNotFoundError: No module named 'utils.datasets'
Sorry but its been a long time so i can not remember exactly what i was doing at that time. You can refer to this repo github.com/mikel-brostrom/Yolov5_StrongSORT_OSNet
U can try 0 for webcam or 'rtsp://exp.com/video.mp4' for RTSP, stream. Actually I don't remember whether I set it up to work with other sources. I have a better version that I built for work that can works with all video sources but I can't share it with you right now. You can refer to this free repo of mikel github.com/mikel-brostrom/Yolov5_DeepSort_OSNet and edit the track.py file to your needs
@@congnhaduong9047 thanks bro, i already made my own dataset. I have trained 300 images, 3 classes > Person, Hat, Shirt < but it there are 2 person it counts Person1 Hat2 Shirt3 and Person4 Hat5 Shirt6... How can i start the count of each class from zero n start counting while they appear?
python track.py --yolo_model yolov5/runs/train/exp2/weights/best.pt --img 2048 --source outStitch345678.avi --save-vid I am using the above command to save the tracked video using deepsort but it is not able to save the video . Can you tell me what's missing from the above line
Nice video How can I display total number of objects in a frame? I have a task which include congestion measurement Let's say a system that alert when there's more than 10 people
@@congnhaduong9047 Yeah thanks for that but I am doing this for my project, so I have to write a paper on that. So, if I will just clone it and use it then will not add any value for my paper. I have to explain maximum of this things. So, any suggestion for that. And please if possible tell me what are the things I have to learn for that ?
@@readbhagwatgeeta3810 yolov5 is based on yolov4 and u can find lots of papers that explains it. DeepSORT is an enhanced version of SORT, StrongSORT is latest. You can google the original paper of DeepSORT, some blogs have explained it as well
@@congnhaduong9047 It have started reading papers on that. So it means after understanding all the papers, then what should I do ? Then I can clone hour git hub directly ? Because I need to show my code to the supervisors, so I can't do cloning ? So, in that case how to approach coding problem ?
@@readbhagwatgeeta3810 u can clone my repo which has yolov5 and deepsort in it and then combine them by yourself. To start, u can first read and understand the process flow of yolov5 in file detect.py of yolov5 repo. Then u add the part of deepsort to it. You can refer how i did it by looking at file app_track.py. But because this is a mini non- commercial project i did for my class, i haven't refractored the code yet so the code is "messy" a little bit.
Em đang gặp vấn đề tương tự trong video là cùng 1 xe nhưng lúc đối tượng là car lúc đối tượng là truck, không biết có cách nào xử lý vấn đề này không anh?
a nghĩ là e có thể đếm số frame xuất hiện của car và truck trong lifetime của nó cnao nhiều hơn thì lấy E muốn sửa nhiều hơn thì clone cái này về r tự sửa lại file detect.py github.com/mikel-brostrom/Yolov5_DeepSort_OSNet chứ repo của a làm cho có nộp bài nên chưa refractor j hết đọc hơi rối
Việt Nam cần người như anh ❤️
Great Job and Educatative
Hey brother. great work. I just wanted to ask you how did you seperate the used zone and the unused zone for your detection; and is it possible to specifiy a crop in the middle for example, and that crop is only where the object detection model works.
I set up these lines manually
@@congnhaduong9047 can you please provide me with the code for that setting. thank you very much
هل اشتغل معاك يا اسامه
Great work.. I hope you upload the entire production system.. How to implement all of these things.
Its just a POC I do for learning CV. I've done a better version for commercial with my team but I cant share or upload it.
Hi Công , cho mình hỏi kết quả bạn chạỵ trên GPU hay CPU vậy ? đạt FPS là bao nhiêu?
Hello, is there a wy to add new type of vehicle for example jeepney, motorcycle, suv and such?
its depends on your object detection model. In this case i used pretrained model of yolov5 which only has some popular types of vehicles. You can train a new model yourself on a vehicles dataset for more types
Ty man. I have a question, if you can replly im glad. Do you know how i can show (in the video) the numbers of cars in each lane ?
its not so hard. Just add some lines of code that specify left/right cars at the database part. See how the data looks like after being uploaded to database at my github link in the description.
Btw, it's my homework excersise so i haven't refractor the code yet, so it''ll be a little bit hard to read and understand the code but basically the main file is the detect.py in yolov5 repo with some modifications
Hey bro
Were you able to get the number of cars in a lane?
@@umarmuhammadi429 its easy man. I've mentioned that in the comment above
@@congnhaduong9047 okay
i am getting this error: kindly help for the same
from utils.datasets import exif_transpose, letterbox
ModuleNotFoundError: No module named 'utils.datasets'
Sorry but its been a long time so i can not remember exactly what i was doing at that time. You can refer to this repo github.com/mikel-brostrom/Yolov5_StrongSORT_OSNet
thxn pro for this amazing video ,but i error line 1207 ,in __getattr__ raise attributeError (" ' {} ' object has no attribute ' {} ' ".format(
HAI
how do i change source video to webcam or rstp url?
U can try 0 for webcam or 'rtsp://exp.com/video.mp4' for RTSP, stream.
Actually I don't remember whether I set it up to work with other sources. I have a better version that I built for work that can works with all video sources but I can't share it with you right now. You can refer to this free repo of
mikel github.com/mikel-brostrom/Yolov5_DeepSort_OSNet and edit the track.py file to your needs
Nice Example. Where we can change tha numbers of
lanes, zones and directión?
Its a demo so i jus hardcoded params and haven't setup a config file for those things
@@congnhaduong9047 thanks for you answer. Where you hardcoded? In detect.py?
@@diegodoy80 I answer to myself /home/movilidad/Vehicle-tracking-main/application/main/infrastructure/helper/zone_drawer_helper.py
Thanks you!
Pro quá idol ơi
Nhưng kh bằng phó chủ nhiệm CLB ạ
How many FPS you got for this and on which GPU?
I coded on my old laptop so fps was just enough for testing. Running inference on this video on colab.
@@congnhaduong9047 Thank you!
how to train my own dataset classes ?
Train your yolov5 model
github.com/ultralytics/yolov5/wiki/Train-Custom-Data
@@congnhaduong9047 thanks bro, i already made my own dataset. I have trained 300 images, 3 classes > Person, Hat, Shirt < but it there are 2 person it counts Person1 Hat2 Shirt3 and Person4 Hat5 Shirt6... How can i start the count of each class from zero n start counting while they appear?
@@diegodonoso5694 I'm afraid you have to edit a lot. you can get ideas from my handlers/track.py file and do the same thing
python track.py --yolo_model yolov5/runs/train/exp2/weights/best.pt --img 2048 --source outStitch345678.avi --save-vid
I am using the above command to save the tracked video using deepsort but it is not able to save the video . Can you tell me what's missing from the above line
hay quá anh ơi thật tuyệt vời
Nice video
How can I display total number of objects in a frame?
I have a task which include congestion measurement
Let's say a system that alert when there's more than 10 people
Thats easy bro, just look around the detection part of yolo or the database part in detect.py
@@congnhaduong9047 thank you very much bro
@@congnhaduong9047 i have checked but i have no idea what to add
@@umarmuhammadi429
len(output) at line 224
github.com/duongcongnha/Vehicle-tracking/blob/main/application/main/infrastructure/handlers/track.py
Hey! Bro can you please help me to make this project? What should be my first step ?
just clone my repo on github and follow the instructions
@@congnhaduong9047 Yeah thanks for that but I am doing this for my project, so I have to write a paper on that. So, if I will just clone it and use it then will not add any value for my paper. I have to explain maximum of this things. So, any suggestion for that. And please if possible tell me what are the things I have to learn for that ?
@@readbhagwatgeeta3810 yolov5 is based on yolov4 and u can find lots of papers that explains it. DeepSORT is an enhanced version of SORT, StrongSORT is latest. You can google the original paper of DeepSORT, some blogs have explained it as well
@@congnhaduong9047 It have started reading papers on that. So it means after understanding all the papers, then what should I do ? Then I can clone hour git hub directly ? Because I need to show my code to the supervisors, so I can't do cloning ? So, in that case how to approach coding problem ?
@@readbhagwatgeeta3810 u can clone my repo which has yolov5 and deepsort in it and then combine them by yourself. To start, u can first read and understand the process flow of yolov5 in file detect.py of yolov5 repo. Then u add the part of deepsort to it. You can refer how i did it by looking at file app_track.py. But because this is a mini non- commercial project i did for my class, i haven't refractored the code yet so the code is "messy" a little bit.
đỉnh quá anh ơi iu anh
Nhận xét từ GS (Quang) giấu tên đầu ngành
Em đang gặp vấn đề tương tự trong video là cùng 1 xe nhưng lúc đối tượng là car lúc đối tượng là truck, không biết có cách nào xử lý vấn đề này không anh?
a nghĩ là e có thể đếm số frame xuất hiện của car và truck trong lifetime của nó cnao nhiều hơn thì lấy
E muốn sửa nhiều hơn thì clone cái này về r tự sửa lại file detect.py
github.com/mikel-brostrom/Yolov5_DeepSort_OSNet
chứ repo của a làm cho có nộp bài nên chưa refractor j hết đọc hơi rối
@@congnhaduong9047 dạ em cảm ơn anh, để em thử lại xem sao
hay zaaaaaaaaaaaaaa
thi đi a chính
rat vinh hanh
anh ơi làm về nhận diện và phát hiên nữ idol JAV đi ạ?
Sắp tới sẽ có em nhé
idol cho e xin chữ ký đi