Can not see finished_classifier.xml file
Dear pro! I tried to convert a picture to an "image_learning.xml" file I cloned your project and do step by step, there was no error!
I got the results from "opencv-haar-classifier-training\classifier" folder There were 1 params.xml file and 9 stage.xml file

I wonder where is the finished_classifier.xml ?
Thanks for help!
Ly Hoang Nam
hi man. what did you do to have vec files in perl bin/createsample.bin. i have try the code yet not creating any file in samples forlder
Dear @johnd3v ! I do as the guide in this repository: Step 5
perl bin/createsamples.pl positives.txt negatives.txt samples 1500\
"opencv_createsamples -bgcolor 0 -bgthresh 0 -maxxangle 1.1\
-maxyangle 1.1 maxzangle 0.5 -maxidev 40 -w 80 -h 40"
Which error occured with you?
@lyhoangnam-archway thanks for the reply.
i got only this sir.

no file created in sample folder
Dear @johnd3v ! It did not throw any error, I think that all seem to be done Try next step(number 6). I think so!
@lyhoangnam-archway thanks for the reply. i tried step6 yet this is the result.
badly need to create my own classifier for my last year research
Dear @johnd3v ! Can you get your result? I still waiting for the author...he do not reply my question!
:( :( :(
Dear @johnd3v ! naotoshio seo explained this mechanism in creating samples. how means, vector samples are images which include positives in negative background images. so, it all depends on your object how complex it is and whether +ve images needed more or -ve images needed more to generate the .vec files. i got this error many times while creating samples using createsamples.pl file at that time i change the ratio of +ves and -ves then it will work fine. and one noticeable point is here size also matters because if positive image is having more resolution than -ve image then it cant be impose its features on -ve background. so its good if all images having same size. but one thing disappointing me is i haven't get exact information on this! till searching for this..........
@lyhoangnam-archway !
There were 1 params.xml file and 9 stage.xml file
I wonder where is the finished_classifier.xml ?
because classifier achieved the accuracy in training the .vec files at the stage of 9th. please look this image.

f you want to convert an intermediate haartraining output dir tree data into a xml file, there is a software at the OpenCV/samples/c/convert_cascade.c (that is, in your installation directory). Compile it. how to compile ? -->> https://www.learnopencv.com/how-to-compile-opencv-sample-code/ so, you can create the cascade.xml file using this command $ convert_cascade --size="<sample_width>x<sampe_height>" <haartraining_ouput_dir> <ouput_file> example : convert_cascade --size="20x20" classifier haarcascade.xml
Dear @saideepthik ! It means that I have to manually merge all stage.xml file to finished_classifier.xml I think that this tool will do all of this step...
@lyhoangnam-archway "I have to manually merge all stage.xml file to finished_classifier.xml I think that this tool will do all of this step..." for this, actually say no need to do manually just give less number of stages while training or else give more positives and negatives do same from first step (delete .vec files in samples folder then do) you will get cascade.xml file
@johnd3v I hope it's not too late. I had the same issue as you do. It was an OpenCV bug. I was working with a newer version of OpenCV (3.4.1). The code works when I use it with OpenCV version 3.2.0. No files were generated because a segmentation fault was thrown by opencv_createsamples. Hope this helps. The issue can be closed.
i already run
perl bin/createsamples.pl positives.txt negatives.txt samples 1500
"opencv_createsamples -bgcolor 0 -bgthresh 0 -maxxangle 1.1
-maxyangle 1.1 maxzangle 0.5 -maxidev 40 -w 80 -h 40"
but there is no sample.vec created, anyone can help me ?
@saideepthik how to change the image ratio ? can you help my problem ?
@arizalzr Ratio in the sense increase or decrease the number of input images (positive images and negative images) for the training. check while testing the image detection whether r u getting more false positives or not, if getting false positives means just take (save as images ) those false positives give as negative images and train the same. observable thing is sometime u need to give more appropriate positive images (depends on how complicated is your object to be detected) it will give good results. try u will get...........
@saideepthik why after run this :
perl bin/createsamples.pl positives.txt negatives.txt samples 1500 "opencv_createsamples -bgcolor 0 -bgthresh 0 -maxxangle 1.1
-maxyangle 1.1 maxzangle 0.5 -maxidev 40 -w 80 -h 40"
there is no sample.vec created ? can you help me to solve this ?