Object Detection OpenCV Python | Easy and Fast (2020)

  Рет қаралды 484,867

Murtaza's Workshop - Robotics and AI

Murtaza's Workshop - Robotics and AI

3 жыл бұрын

In this tutorial, we are going to learn how to detect objects using OpenCV and python. The Object Detection OpenCV method we will use is a sweet balance between speed and accuracy. Unlike many other object detection methods, we will be able to run this in real-time with a good amount of accuracy.
🚀🚀 My Urdu/Hindi AI KZfaq Channel 🚀🚀
/ @murtazahassan01
Download Code:
www.computervision.zone/cours...
Premium Courses:
✔️ Computer Vision Game Development Course:
bit.ly/3ttLZ2s
✔️ Computer Vision with Arduino Course:
bit.ly/3wzLB4m
✔️ Advanced Drone Programming Course:
bit.ly/3qs3v5g
✔️ Learn to Build Computer Vision Mobile Apps:
bit.ly/3uioY1J
✔️ Jetson Nano Premium Course:
bit.ly/3L8uIlF
⚙️⚙️⚙️--My Gear - ⚙️⚙️⚙️
👉 Complete Gear 💈: www.computervision.zone/tech-...
👉 My PC Specs 🖥️: www.computervision.zone/tech-...
👉 My Video Shooting Gear📽️ : www.computervision.zone/tech-...
👉 My Laptops 💻: www.computervision.zone/tech-...
👉 Educational Products🧑‍🎓: www.computervision.zone/tech-...
👉 KZfaq Starter Kit 🔴: www.computervision.zone/tech-...
Follow Me:
TikTok: bit.ly/3Vo76OQ
Facebook Group: bit.ly/3irDcb7
Discord: bit.ly/3JvyxAM
Facebook Page: bit.ly/3IvpU7W
Instagram : bit.ly/3NdGME3
Website: bit.ly/3ICFTS0
Github: bit.ly/3woU6PS
#ComputerVision
#OpenCV
#CVZone

Пікірлер: 725
@pete1231
@pete1231 3 жыл бұрын
This was great, so easy and quick. I watched so many other tutorials and there are always a million dependencies and errors, this was awesome, thanks!
@_BENJOSEPH
@_BENJOSEPH 2 жыл бұрын
how to download COCO dataset?
@karatekidj1380
@karatekidj1380 2 жыл бұрын
Peter, could you possibly help me with fixing my error?
@parthverma7089
@parthverma7089 Жыл бұрын
i am having issues in getting the resource files such as ssd mobile net v3 and frozen inference....can u plz help me
@Ibloop
@Ibloop 28 күн бұрын
@@parthverma7089 ​ If you still care go to the link in the description under download code, and then enroll for the course and then go to the lesson that says "Code Files" and then download the files at the top, it might not notify you that you downloaded the files but they will go onto your system
@murtazasworkshop
@murtazasworkshop 3 жыл бұрын
If you would like to follow along, here are the prerequisites: 1. Pycharm IDE with opencv installed 2. Coco.names file 3. Config and Weights file 4. Test image or webcam All the files can be downloaded from the below link under the "Intermediate" section by the heading "Object Detection Opencv" www.murtazahassan.com/courses/opencv-projects
@LearningTechCom
@LearningTechCom 3 жыл бұрын
" classIds, confs, bbox = net.detect(img,confThreshold=thres" this code getting error" what can i do
@mrSolo295
@mrSolo295 3 жыл бұрын
there is nothing inside "-----Intermediate----" section??
@yunusemre9044
@yunusemre9044 3 жыл бұрын
I can't find the files under the intermediate section. Can u please share them again? We love the video, it rocks!
@bobyau8755
@bobyau8755 Жыл бұрын
The weights Are in the dataset folder downloaded from kaggle
@yenupurigyaneswarasaikumar650
@yenupurigyaneswarasaikumar650 11 ай бұрын
classIds, confs, bbox = net.detect(img, confThreshold=thres) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ i am getting error
@shepbryan4315
@shepbryan4315 2 жыл бұрын
This was super helpful! Your live coding is very impressive. Thanks!
@bryanirvine3914
@bryanirvine3914 3 жыл бұрын
Wonderful tutorial. Thank you so much for sharing your knowledge for free, you make the world a better place.
@murtazasworkshop
@murtazasworkshop 3 жыл бұрын
You are so welcome!
@baitywahidiah2313
@baitywahidiah2313 3 жыл бұрын
Hi can i know, how to make object identification for trash bin, example, my camera detects platics,the shutter for plastics compartment will open. And vice versa
@qweqwe-kd4yc
@qweqwe-kd4yc 3 жыл бұрын
Good Job Murtaza. Hello from Turkiye to Pakistan
@lorddevincecifra3200
@lorddevincecifra3200 3 жыл бұрын
How to connect the camera to the laptop? In order for it to access the program. And does this needs a microcontroller?
@hilmannaufal7128
@hilmannaufal7128 3 жыл бұрын
8:48 "Sometime time it good to be lazy" quote of the day😁
@yotte8846
@yotte8846 Жыл бұрын
Is coco dataset tuple and can i modify it as i need to person to be detected like person one and person two so is that possible ?
@edSabio572
@edSabio572 3 жыл бұрын
Dr. Murtaza, I need to know how to close up the 'complete' course in your website. At times, I play the video straight from youtube. when I log in in my account it is showing not complete. My question is, do I have to log in to continue the lesson? there is no option to 'continue' later...
@patelgaurang8766
@patelgaurang8766 2 жыл бұрын
I'm getting error in net = cv2.dnn_DetectionModel....... what should i do?
@pseudohawk1656
@pseudohawk1656 2 жыл бұрын
How can i get the width or height of the rectangle in pixel? I want to use it to measure distance along with detetecting the object
@hackercop
@hackercop 3 жыл бұрын
Thanks so much for making this, I learn't a lot from you.
@luisfernandomanzano9953
@luisfernandomanzano9953 2 жыл бұрын
This is just gold. Thank you so much Murtaza I'm a broke student but eager to dive into Computer Vision and thanks to your altruism in making this content I am can to learn something that otherwise I would not be able to. Thank you
@parthverma7089
@parthverma7089 Жыл бұрын
i am having issues in getting the resource files such as ssd mobile net v3 and frozen inference....can u plz help me
@atulchandradash8477
@atulchandradash8477 3 жыл бұрын
Awesome Sir ...... This the one of the best video i seen in youtube......you code are esay to understand.....thank so much sir... That One is really esay to use .....
@bhubeshsr6281
@bhubeshsr6281 3 жыл бұрын
need weekly thrice videos like these please I am sharing this with all my friends
@vinayakdhinde5606
@vinayakdhinde5606 3 жыл бұрын
which function I need to add if I want to count how many times I lost my object from screen
@aydnaltun2573
@aydnaltun2573 3 жыл бұрын
Sir , what if we wanna detect only a spesific object such as pedestrian or car what kind of methot should we use ?
@hiteshsingh2222
@hiteshsingh2222 3 жыл бұрын
Incredible... Thanks for the effort and time
@universalduggal1708
@universalduggal1708 3 жыл бұрын
I went on your website to see the weight files and couldn't find them. Where are they?
@ddtdilireba
@ddtdilireba 3 жыл бұрын
yes...I also couldn't find it
@mark_coker
@mark_coker 2 жыл бұрын
www.computervision.zone/topic/basic-code/
@am_editz9145
@am_editz9145 Жыл бұрын
Those are paid 😥
@llewsub
@llewsub 19 күн бұрын
@@am_editz9145 So this whole tutorial is a waste of time then lol wtf
@michaelderamus662
@michaelderamus662 2 жыл бұрын
Does this work anymore? I'm getting an error for the following. net = cv2.dnn.DetectionModel(weightsPath, configPath) AttributeError: module 'cv2.dnn' has no attribute 'DetectionModel'
@albertjackinson
@albertjackinson 3 жыл бұрын
I will definitely put this to use in my own project sometime! Thank you for making this tutorial.
@shova524
@shova524 2 жыл бұрын
Can i get your project name?
@gabrielaz.4792
@gabrielaz.4792 Жыл бұрын
Is it possible to extract the deteted box with an object as a separate image? I need it for my project and hoped it could work this way but I am lost....
@Renatic123
@Renatic123 3 жыл бұрын
Where can we found the fronzen_interference_graph? Thank you
@dennisasamoah2213
@dennisasamoah2213 3 жыл бұрын
great tutorial from a great teacher
@amirhosseinesteghamat7621
@amirhosseinesteghamat7621 3 жыл бұрын
Can you please give straight link to the dataset and the files you add to project at the start of video
@rajvindermann7655
@rajvindermann7655 3 жыл бұрын
Hi, is it possible to use opencv to do custom object detection? Thank you.
2 жыл бұрын
How to get the initial files you put in to project? Coco names and SSD files.
@ilkeraykut7064
@ilkeraykut7064 3 жыл бұрын
I wanna detect some electronic materials like mosfet or transistor or resistor.What should I do for this?Thank you.
@vyjayanthiseshadri4318
@vyjayanthiseshadri4318 2 жыл бұрын
thank you soo muchh!Very informative and detailed video
@aykutsirma4260
@aykutsirma4260 3 жыл бұрын
I am getting this error: net = cv2.dnn_DetectionModel(weightsPath,configPath) AttributeError: module 'cv2.cv2' has no attribute 'dnn_DetectionModel' Do you know or anyone know how to solve this problem? thank you.
@alasthereshopeforyou.1719
@alasthereshopeforyou.1719 Жыл бұрын
Thank you very Much. This has been very very helpful!
@mmf3775
@mmf3775 3 жыл бұрын
Great Tutorial Murtaza .from Iran to Pakistan
@jaymenon3693
@jaymenon3693 3 жыл бұрын
Can I use my custom objects for detection like Nuts and Bolts? And can I use that model in R-Pi 4GB?
@laurajanenunez1234
@laurajanenunez1234 3 жыл бұрын
is there any way to train new image, or for example i want to classify different types of cakes, please reply sir I really want this for my project
@sayanmondal161
@sayanmondal161 Жыл бұрын
SystemError: returned a result with an exception set Sir can you help me out with this? I've searched for this error in several places but can't seem to be of help... I'm using VS Code as a platform... Thank You
@hilary410
@hilary410 11 ай бұрын
Thanks for the video! Love it! Can you do a tutorial on adding custom classes to the coco dataset for Object Detection with OpenCV Python? :)
@tinmar8164
@tinmar8164 2 жыл бұрын
is it possible to include more objects to be detected? like some custom trained objects
@rhalppalanca3273
@rhalppalanca3273 3 жыл бұрын
Hello, sir a nice tutorial. but can ask if object detection can light LED after the detection is done? I'm trying to apply it in RPI and in real-time
@muhammadshifa4886
@muhammadshifa4886 3 жыл бұрын
That great. very nice. I have one question how we can compute its confusion matrix, precision, recall with intersection over union IoU in Python?
@longphan9475
@longphan9475 3 жыл бұрын
can you help "SystemError: returned a result with an error set
@mrclash1357
@mrclash1357 2 жыл бұрын
hi its good tutorual but can you tell me how I add anthor coco names like names that were not in coco name if I add that can be destroy the code?
@eslammedhat7151
@eslammedhat7151 3 жыл бұрын
How can I Apply this object detection model on a reception robot and detect the floor to be able to walk and avoid objects ?? Any idea :) Thanks
@mcmouli2002
@mcmouli2002 3 жыл бұрын
Excellent explanation. You made me to fell in love with openCV.
@Idan_Nesimov
@Idan_Nesimov 2 жыл бұрын
what means box[2] and box[3] ?
@allenqueen
@allenqueen 2 жыл бұрын
You sir, are a god amongst men.
@angelortiz3564
@angelortiz3564 3 жыл бұрын
where can I find the .pb and the .pbtxt files you used?
@parthverma7089
@parthverma7089 Жыл бұрын
i am having issues in getting the resource files such as ssd mobile net v3 and frozen inference....can u plz help me
@lifeconfused52
@lifeconfused52 Жыл бұрын
Can anyone tell me how to get the coordinates of rectangle in object detection ? I wanna crop the the image within the rectangle.
@Maihoe1
@Maihoe1 3 жыл бұрын
Can I do this using a hikvision IP camera rather than webcam? If so then can you do a quick tutorial on this? Thanks for your hard work. It is much appreciated
@aelyr2710
@aelyr2710 Жыл бұрын
how do I make an object recognizing drone that will prompt will send a prompt to a software?
@Java-fj3mk
@Java-fj3mk Жыл бұрын
Thanks a lot for this great tutorial. I have watched couple of the videos here in KZfaq, but no one make it straight forward like you. In line 22 why you didn't flatten the bbox when you use it with the zip function?
@gabetower6165
@gabetower6165 3 жыл бұрын
What is the easiest why to train a custom model that will work with this script.
@h-electronics602
@h-electronics602 3 жыл бұрын
what is the difference between your method and tensorflow?
@nogafathi2359
@nogafathi2359 3 жыл бұрын
My research in Fully convolution Network.. in small object detection so from. where I should be start.. please help me... give me some advices
@aradhyaupadhyay3518
@aradhyaupadhyay3518 3 жыл бұрын
Sir after starting first 4 line it shows an error imshow() takes 1 positional arguments but 2 were given .... Sir plz solve my problem
@NabilAfi
@NabilAfi 2 жыл бұрын
excuse me sir, I received this error when I ran your code line 13, in net = cv2.dnn_DetectionModel(weightsPath,configPath) SystemError: returned a result with an error set what should I do with this
@overflow5027
@overflow5027 3 жыл бұрын
Interesting cant wait!
@javertnone6262
@javertnone6262 3 жыл бұрын
I'm having trouble finding the ssd file, can anyone help me, please.
@eij1704
@eij1704 3 жыл бұрын
I tested the file when I reached print(ClassIds, bbox) But came out with an error set, what am I doing wrong?
@ishikabanga2552
@ishikabanga2552 Жыл бұрын
i have an issue , i want to run this code helmet detection . i have tried it , my image is of a person riding a bike with helmet but it is dtetction the person only written as person in the bbox . please help
@ezzeldin101
@ezzeldin101 3 жыл бұрын
Sir can you put the links of the resources files in the description, please? We cannot perform anything without these files.
@mohammedkamran8559
@mohammedkamran8559 2 жыл бұрын
Did u get those files??
@mohammedazzan7529
@mohammedazzan7529 Жыл бұрын
@@mohammedkamran8559 did you get them?
@krizz5825
@krizz5825 Жыл бұрын
​@@mohammedazzan7529 ys
@omereroglu6772
@omereroglu6772 9 ай бұрын
@@krizz5825 how?
@Manojkumar-vh4tc
@Manojkumar-vh4tc 2 жыл бұрын
I am about to implement Distance Measurement between the named objects, can I able to successfully implement ?
@mhmaryam9359
@mhmaryam9359 3 жыл бұрын
Merciiiiii pour votre effort
@Ashukr711
@Ashukr711 3 жыл бұрын
hey i can not access the code from the link in your description. Can you please fix it.
@nobody-kn9kw
@nobody-kn9kw 6 ай бұрын
I gotta say, this video was just what I was searching for, great work man!!!
@contentkaali
@contentkaali 5 ай бұрын
I have error in classIds,confs,bbox=net.detect(img,confThresholf=thres) Assertion failed, !ssize.empty() in function What should I do?
@Python-eu7ok
@Python-eu7ok 2 жыл бұрын
Thanks Really Helpful I love 🌹 your videos
@2000varma
@2000varma 3 жыл бұрын
Excellet tutorial! Can you please explain why we have set the input parameters(Size, Scale, Mean, SwapRB) to the net object?
@parthverma7089
@parthverma7089 Жыл бұрын
i am having issues in getting the resource files such as ssd mobile net v3 and frozen inference....can u plz help me
@mohsinrasul7140
@mohsinrasul7140 3 жыл бұрын
where are you getting the coco.names file from? I cant locate your files directly from the link you have provided in the video desciption.
@murtazasworkshop
@murtazasworkshop 3 жыл бұрын
Follow the link in the description and enroll in the course at the top of the page to get access.
@israelayobamiji1652
@israelayobamiji1652 3 жыл бұрын
Please sir, can you kindly update the description of the video with the link of coco name and frozen interface graph.pb
@ofekyofi
@ofekyofi 3 жыл бұрын
Great video!! everything worked perfectly
@krishnaganesh4825
@krishnaganesh4825 3 ай бұрын
can u pls explain how to do it
@irvinsanchez3405
@irvinsanchez3405 2 жыл бұрын
What cam are you using?, Are you using a ESP32?
@learnmechatronics2545
@learnmechatronics2545 Жыл бұрын
is there anything opencv which detects logos on shirts with relatively good accuracy and speed?
@gouruhemanth
@gouruhemanth 2 жыл бұрын
dir, please tell us ,the method used is machine learning or transfer learning?? please reply fast.
@nadeemshaikh9257
@nadeemshaikh9257 3 жыл бұрын
Assalamualykm bro yr videos help me alot ♥
@Damirnah
@Damirnah 3 жыл бұрын
Help pls. When it detects more than one object in gives out an error: cv2.putText(img, classNames[classId-1].upper(), (box[0]+50, box[1]+30), cv2.FONT_ITALIC, 1, IndexError: list index out of range Edited: in fact it shows few objects (with bad accuracy) for a few secs and then gives an error because classIds has index 90 and that is out of coco.names range
@JMRVRGS
@JMRVRGS 2 жыл бұрын
same is there any fix?
@dans-designs
@dans-designs 2 жыл бұрын
I am getting the same error but with numbers 44 and 77... which is definitely within the coco.names range.... for those having issues with over 90 being detected, make an entry in coco.names for that number and see if it fixes it??
@sidharthans4866
@sidharthans4866 Жыл бұрын
Hi sir, how can i set specific colors for specific objects? Like red for persons, blue for car etc. Please help
@janabj3335
@janabj3335 2 жыл бұрын
which software you using? plz tell me @Murtaza's
@aaronmcneil6624
@aaronmcneil6624 3 жыл бұрын
Is there a link to where we can get the files you used???
@csemrinmoy
@csemrinmoy 2 жыл бұрын
Which algorithm is used for detection?
@kanonghaemi2444
@kanonghaemi2444 3 жыл бұрын
you are BEST . tanx for sharing .
@PainReliefhealer
@PainReliefhealer 3 жыл бұрын
@Murtaza's Workshop - Robotics and AI,where is the link for the pbtxt & coco file names
@murtazasworkshop
@murtazasworkshop 3 жыл бұрын
follow the link in the description
@asirisudarshana536
@asirisudarshana536 3 жыл бұрын
I couldnt find frozen_inference file it also not in your GitHub..where can i find exact file sir?
@freemanwong106
@freemanwong106 3 жыл бұрын
thank you the video. I wonder where we train the model?
@keshavharipersad2024
@keshavharipersad2024 2 жыл бұрын
hello, great tutorial! this made me win a hackathon, but how can i track the object with a tello drone? i tried to merge it with the previous code of the telo drone face tracking but i got stuck somewhere. please help?
@rohitpandey9920
@rohitpandey9920 Жыл бұрын
When I execute this line on jupyter notebook :- model = cv2.dnn_DetectionModel(frozen_model,config_file) I am getting the below error :- returned a result with an error set Please help me out!!
@innerpeace2780
@innerpeace2780 8 ай бұрын
thanks for the video, it was very interassing but you didn't show us hoiw we can have ssd_mobilenet_v3_large_coco_2020_01_14.pbtxt and frozen_inference_graph.pb! please can you tell me how ?
@StormRaider2010
@StormRaider2010 2 жыл бұрын
Thanks a lot for the tutorial, as usual well explained and straight to the point. Can you please point me to where I can download all the files you have imported at the start of the lesson. I can't find them. Thanks
@mohammedkamran8559
@mohammedkamran8559 2 жыл бұрын
Did u get them??
@aniketkumarsingh2849
@aniketkumarsingh2849 2 жыл бұрын
@@mohammedkamran8559 yes i need them'
@vikky452
@vikky452 Жыл бұрын
sir please help, its showing Traceback (most recent call last): File "H:\object_detection\object_d.py", line 31, in cv2.putText(img,classNames[classId-1].upper(),(box[0]+10,box[1]+30), IndexError: list index out of range
@hardcore5925
@hardcore5925 5 ай бұрын
same , did you find the fix?
@josephkamwendo8455
@josephkamwendo8455 3 жыл бұрын
where is the link to download the mobilenet ssd can you help
@sakshisinghal8008
@sakshisinghal8008 3 жыл бұрын
where i can find these coco.names and other files on internet ?? there is no mobilenet ssd file in opencv doc.
@murtazasworkshop
@murtazasworkshop 3 жыл бұрын
Follow the link in the description and enroll in the course at the top of the page to get access.
@Alex-wl3ze
@Alex-wl3ze 2 жыл бұрын
Where are the links for the coco dataset and the ssd_mobile?
@eSeMGie
@eSeMGie Жыл бұрын
I know the .pb files can be downloaded directly from your website but I wonder where did You get it from originally?
@c16harsaran18
@c16harsaran18 3 жыл бұрын
i am getting a error net = cv2.dnn_DetectionModel(weightsPath, configPath) SystemError: returned a result with an error set. please help.
@thinhtruong5831
@thinhtruong5831 3 жыл бұрын
Thanks you very much for this video. I hope you will guide custom Data Mobile net ssd
@alexandrpetrov1110
@alexandrpetrov1110 3 жыл бұрын
Thanks!
@Grenadier-qg5ym
@Grenadier-qg5ym 3 жыл бұрын
Any idea how to get other things detected that are not on the list?
@JH-on1rw
@JH-on1rw 2 жыл бұрын
Thanks for lecture, Did you run Pycharm to using code?
@cyberthunder1012
@cyberthunder1012 3 жыл бұрын
love your work from bangladesh
@sohailali5741
@sohailali5741 3 жыл бұрын
Excellent tutorial.! Can you please make a tutorial on how to train Object Detection models using our own dataset?
@shaik.gulshanmohiddin5966
@shaik.gulshanmohiddin5966 3 жыл бұрын
towardsdatascience.com/creating-your-own-object-detector-ad69dda69c85 u can check here!!
@گیمینگ
@گیمینگ 3 жыл бұрын
Chekc the ai guy gethub he is explaining everything good but not perfect, I need a video as you said to
@brokeunistudent2474
@brokeunistudent2474 3 жыл бұрын
@@shaik.gulshanmohiddin5966 hey shaik, im having some issues with the installation, could you help me solve it? cannot import name 'model_lib_v2' from 'object_detection"
@fanymaulidinr9907
@fanymaulidinr9907 3 жыл бұрын
i got an error, "line 31" List Out of The Range. what should I do?
@balensoran3666
@balensoran3666 2 жыл бұрын
did you find the solution???? please help me
Object Detection Raspberry Pi using OpenCV Python
31:34
Murtaza's Workshop - Robotics and AI
Рет қаралды 172 М.
Feature Detection and Matching + Image Classifier Project | OPENCV PYTHON
45:34
Murtaza's Workshop - Robotics and AI
Рет қаралды 158 М.
World’s Largest Jello Pool
01:00
Mark Rober
Рет қаралды 63 МЛН
Best Toilet Gadgets and #Hacks you must try!!💩💩
00:49
Poly Holy Yow
Рет қаралды 16 МЛН
Summer shower by Secret Vlog
00:17
Secret Vlog
Рет қаралды 11 МЛН
Text Detection using Neural Networks | OPENCV Python
1:26:24
Murtaza's Workshop - Robotics and AI
Рет қаралды 144 М.
Easy Programming of  Tello Drone | Python OpenCV Object Tracking
12:26
Murtaza's Workshop - Robotics and AI
Рет қаралды 197 М.
REAL TIME OBJECT MEASUREMENT | OpenCV Python (2020)
53:25
Murtaza's Workshop - Robotics and AI
Рет қаралды 243 М.
Object Detection Removing Duplicates | OpenCV Python
23:54
Murtaza's Workshop - Robotics and AI
Рет қаралды 27 М.
Traffic Signs Classification Using Convolution Neural Networks CNN | OPENCV Python
17:59
Murtaza's Workshop - Robotics and AI
Рет қаралды 170 М.
Tracking Objects | OpenCV Python Tutorials for Beginners 2020
18:28
Murtaza's Workshop - Robotics and AI
Рет қаралды 129 М.
FACE RECOGNITION  + ATTENDANCE PROJECT | OpenCV Python | Computer Vision
52:24
Murtaza's Workshop - Robotics and AI
Рет қаралды 1,6 МЛН