Ask Your Question

Rolo's profile - activity

2019-08-05 06:39:28 -0500 received badge  Famous Question (source)
2017-04-04 03:37:34 -0500 received badge  Notable Question (source)
2016-06-16 02:43:40 -0500 received badge  Popular Question (source)
2015-10-04 19:08:04 -0500 received badge  Student (source)
2014-03-16 14:42:03 -0500 received badge  Editor (source)
2014-03-16 11:32:41 -0500 commented answer Logo Text Detection Accuracy

Thanks for the tip berak :)

2014-03-16 10:47:13 -0500 answered a question Logo Text Detection Accuracy

Friendly bump. Really looking for some answers on this seemingly 2d detection using opencv. Thanks so much.

2014-03-15 09:51:04 -0500 commented question Logo Text Detection Accuracy

Can anyone please clarify the above for me?

2014-03-13 13:17:04 -0500 asked a question Logo Text Detection Accuracy

Hey everyone,

I'm attempting to identify store logos using a haar cascade classifier I trained. It was trained using 60 positive images and ~600 negative images.

My question comes about because the images in which I am attempting to find the textual logo, there also exists other text.

OpenCV is determining this "other" text to in fact be the found trained logo. Sample image sizes were 90x30. Sample image used in detection is 300px wide by whatever length is needed to maintain aspect ratio.

So I'm wondering a few things:

  1. Is OpenCV distorting the text in my positive samples to the extent that other text is being detected?
  2. Should I be fine with the number of samples listed above? I followed the tutorial here, though I have heard from other tutorials that 1000's of samples is needed?
  3. Are my sample image sizes okay? I've read a few things about opencv preferring 25px by 25px ?
  4. When training the classifier, I limited it to 5 stages to save time. How much more accurate would the classifier be with say 20 stages? Or is the accuracy only relative to the number of positive samples?

Thanks so much for any input you can provide on this. I'm really looking forward to generating this custom haar file and having it work well.

Very much value your comments :)

Please let me know if I'm missing something trivial :)


2014-03-13 13:04:30 -0500 answered a question Error in classifier?

This error was actually occurring because of an error in the cascade file. The method I was using for detection required some specific changes. Closing :)

2014-03-06 14:18:48 -0500 commented question Error in classifier?

I should mention that this classifier was made using opencv_traincascade. I am going to attempt to rebuild it using opencv_haartraining.

2014-03-06 13:44:49 -0500 asked a question Error in classifier?

Hi everyone,

I've built a classifier file, and I am getting the following error when attempting to use it (to detect a custom image/shape).

OpenCV Error: Unspecified error (The node does not represent a user object (unknown type?)) in cvRead, file /tmp/opencv/opencv-2.4.7/modules/core/src/persistence.cpp, line 4996 terminate called after throwing an instance of 'cv::Exception' what(): /tmp/opencv/opencv-2.4.7/modules/core/src/persistence.cpp:4996: error: (-2) The node does not represent a user object (unknown type?) in function cvRead

I know that the original haarcascade_frontalface_alt2.xml file I used during testing still works well, so not sure what the differences might be that are leading to the above error.

Any direction you could point me in would be greatly appreciated :)


2014-03-06 05:52:04 -0500 received badge  Scholar (source)
2014-02-24 13:47:10 -0500 commented answer Cascade Training: killed and bad_alloc

Thank you so much for your response :) I've passed the bad_alloc error and while I'm not 100% certain I believe the secret sauce may have been the -nonsysm -mem 512 addition to the opencv_traincascade call.

I will follow up again once the training has completed.

2014-02-24 11:14:29 -0500 asked a question Cascade Training: killed and bad_alloc

Hi everyone,

I have OpenCV 2.4.7 installed on Amazon Linux (similar to Centos 6 - 64-bit). I've been following several tutorials online to create haar cascade classifier files, but have run into issues with both commands: opencv_traincascade and opencv_haartraining

In my experiments I have 40 positive images and 664 negative images (all cropped to w=300 h=100).

The tutorial used for generating samples etc. was found here:

1) Command: opencv_traincascade -data classifier -vec samples.vec -bg negatives.txt -numStages 20 -minHitRate 0.999 -maxFalseAlarmRate 0.5 -numPos 40 -numNeg 664 -w 300 -h 100 -mode ALL -precalcValBufSize 1024 -precalcIdxBufSize 1024

Result: terminate called after throwing an instance of 'std::bad_alloc' what(): std::bad_alloc Aborted

2) Command: opencv_haartraining -data classifier -vec samples.vec -bg negatives.txt -nstages 20 -minhitrate 0.995 -maxfalsealarmrate 0.5 -npos 40 -nneg 664 -w 300 -h 100 -mode ALL

Result: Stuck at stage 0 and the script simply returns the word "Killed"

Any help of experience anyone can share would be greatly appreciated. Please also respond if you believe I need to supply more information. New to cascade training.