Training Haar cascade object detection - OpenCV with Python for Image and Video Analysis 20

sentdex · 151K views · 2016 · 18:02

Open on YouTube

Computer vision, speech & NLPPython, Ruby & scripting languagestutorial

Why Stack Overflow recommends it

Stack Overflow users link it when someone wants to train their own Haar cascade classifier instead of relying on OpenCV's bundled face detectors.

Recommended by 2 people across 2 different months, 2017 to 2019.

What it is

A tutorial from sentdex, part 20 of his OpenCV with Python series, showing how to train a custom Haar cascade classifier from sets of positive and negative images. It walks through the training workflow used for general object detection and recognition with OpenCV.

What people said

Recommends chrisckwong821 · 2017-09 · Stack Overflow · on “How to improve face detection performance with OpenCV on Android?”

I saw you have implemented one haar classifier only. I assumed you use the frontleface one. You may incorporate the profile face classifier(available in opencv haar package) in an else statement to increase accuracy. In general, you can train any classifier u want and incorporate them. For training a classifier, this is an awesome video here [this video]

Recommends Tegr4 · 2017-11 · Stack Overflow · on “Making my own haarcascade”

I followed this video and made Haarcascades for bikes and heavy vehicle detection and it was helpful SentDex Making our own HaarCascades [this video]

Cites lucians · 2019-05 · Stack Overflow · on “HaarCascade training: merge .lst files”

I am working on an own object detector using HaarCascade. BTW, I am stucked at some point, which I'll explain below. The situation it's this: - I collected 100 images of my object (let's say apples) - I collected about 1500 negatives images - I created negatives.txt , a file which contains paths to the negatives images - I created positives.txt , a file which contains paths, number of objects, coordinates and dimensions of my positive images Now, this is the problem. Using opencv_createsamples.exe to augment my data/images, I saw that if I execute it (with same parameters) for each object image, the output will be more or less a 1000 positive images (negatives background + object) together w