Ask Your Question

synome's profile - activity

2015-10-27 20:42:46 -0600 commented question Save an Face Detection

Hi berak. After removing the .clone() it was saved! But...It does not appear in the gallery ... why? And...while it has been detected, not only partially saved. When you do not know what is stored. Image also becomes rough. It is full of problems...

2015-10-25 20:05:34 -0600 commented question Save an Face Detection

Hi berak. It is written. But it is not saved. My code is wrong?

2015-10-23 03:10:17 -0600 received badge  Editor (source)
2015-10-23 03:09:10 -0600 asked a question Save an Face Detection

Hi all!!!

Sorry...I can't English.(Using Google Translation)

I want to save in the detection window as an image from the movie by using the Face Detection of OpenCV sample program.

1)Run the application and error does not occur

2)It can not be saved image in the detection window

3)Even stored, stores the same image in a large amount or app is shutdown feel uneasy.

Is there a solution for this problem?

Please help me.

Thanks for reading.

My code is follow.

    Rect[] facesArray = faces.toArray();
    for (int i = 0; i < facesArray.length; i++){
        Core.rectangle(mRgba, facesArray[i].tl(), facesArray[i].br(), FACE_RECT_COLOR, 3 );

    File mediaStorageDir = new File(
             Environment.getExternalStorageDirectory().getPath() + "/DCIM/100ANDRO/");
        Mat face = mRgba.submat(facesArray[i].clone());
        Highgui.imwrite(mediaStorageDir + Integer.toString(i) + ".jpg", face);
    }
2015-09-11 02:39:24 -0600 commented answer opencv_traincascade line 152

You had said that of this book.

https://www.packtpub.com/application-...

amazing! ! I am looking forward to October.

2015-09-10 19:50:43 -0600 received badge  Enthusiast
2015-09-02 21:44:17 -0600 commented answer opencv_traincascade line 152

Hi Steven,

Thanks you. You're a genius.

Sorry...I don't know PacktPub book,What should I do?

It was work by the following test command

opencv_traincascade -data sample -vec sample.vec -bg bg.txt -numPos 90 -numNeg 10 -featureType HAAR -mode ALL -w 30-h 17 -precalcValBufSize 256 -precalcIdxBufSize 256

but...Kill the stage 19 is finished. This is where looking answer.

2015-09-02 21:41:40 -0600 received badge  Scholar (source)
2015-09-02 21:40:07 -0600 received badge  Critic (source)
2015-09-02 21:39:29 -0600 received badge  Supporter (source)
2015-09-02 03:05:04 -0600 asked a question opencv_traincascade line 152

Hi All,

I am trying to make their own cascade classifier.

Here's what I've done:

1)positive file

opencv_createsamples.exe -img sample.png -vec sample.vec -num 1000 -bgcolor 255 -randinv -w 196 -h 106

2)negative file

bg.txt in image PATH. (PATH + name.jpg&png&gif)

3)traincascade

opencv_traincascade -data sample/ -vec sample.vec -bg bg.txt -numPos 900 -numNeg 270 -featureType HAAR -mode ALL

But...Here, the error will occur.

Error code.

===== TRAINING 0-stage =====

OpenCV Error: Assertion failed (_img.rows * _img.cols == vecSize) in CvCascadeIm ageReader::PosReader::get, file C:\builds\master_PackSlave-win32-vc12-shared\opencv\apps\traincascade\imagestorage.cpp, line 152

Nothing no clue.

I do not know what to do.

Please help me.

Sorry...I can't English.(Using Google Translation)

Thanks for reading.