Ask Your Question

Borneq's profile - activity

2014-06-12 13:17:55 -0600 commented question My xml train file differ than predefined xml

I must use opencv_haartraining.exe instead of opencv_traincascade.exe? But opencv_haartraining.exe causes error

2014-06-12 12:36:22 -0600 asked a question My xml train file differ than predefined xml

I have predefined XML in c:\opencv\sources\data\haarcascades\ My generated xml is differ, because: - predefined are big or pretty big: 280 KB - 3.6 MB - structure diffs: in predefined is:

    <_>
      <!-- tree 13 -->
      <_>
        <!-- root node -->
        <feature>
          <rects>
            <_>11 9 4 7 -1.</_>
            <_>11 9 2 7 2.</_></rects>
          <tilted>0</tilted></feature>
        <threshold>8.6949411779642105e-003</threshold>
        <left_val>0.1258095055818558</left_val>
        <right_val>-0.4798910021781921</right_val></_></_>
    <_>
      <!-- tree 14 -->

Whereas in my xml is:

<_>
  <rects>
    <_>
      0 2 33 1 -1.</_>
    <_>
      11 2 11 1 3.</_></rects>
  <tilted>0</tilted></_>
<_>

I badly create it? I have 82 positive images, crate pos.vec by opencv_createsamples.exe and run

c:\opencv\build\x86\vc10\bin\opencv_traincascade.exe -data dir -vec pos.vec -bg negative\neg.txt -numPos 82 -numNeg 20 -w 40 -h 40

2014-06-12 07:10:43 -0600 commented question Training stop at 8-th stage

Pos count consumed 75 : 75

2014-06-11 16:46:28 -0600 commented question Training stop at 8-th stage

I create batch and call it from console

2014-06-11 14:22:39 -0600 commented question Training stop at 8-th stage

No messages, process stop

2014-06-11 12:19:41 -0600 commented question opencv_traincascade.exe and background file

Now I has 65 positives and 10 negatives

2014-06-11 09:34:39 -0600 commented question opencv_traincascade.exe and background file

My result: https://i.imgur.com/abQYlNp.jpg Error because 10 positive and 10 negative is too small, or 8 stages is too small; It seems that find negative, not positive images

2014-06-11 09:20:34 -0600 asked a question Training stop at 8-th stage

I have 10 positive and 10 negative images.

d:\opencv\build\x86\vc10\bin\opencv_traincascade.exe -data dir -vec pos.vec -bg negative\neg.txt -numPos 10 -numNeg 10 -w 40 -h 40

Stages 0-7 are fast but stop at 8-th state; if I add "-numStages 8" is OK - create cascade.xml, but if should be only 8 stages?

2014-06-11 09:13:17 -0600 commented question opencv_traincascade.exe and background file

OK, negative.txt contain only image names, not rectangles

2014-06-11 08:49:13 -0600 commented question opencv_traincascade.exe and background file

negative.txt is the same as neg.dat where is list of negative images and rectangles like 01.jpg 1 0 0 54 67? in negative.txt pathes of images are stored with relative to negative.txt ?

2014-06-11 08:10:28 -0600 received badge  Editor (source)
2014-06-11 08:06:11 -0600 asked a question opencv_traincascade.exe and background file

I create 10 samples and 10 negative samples. In positive/ directory is 10 .jpg files from 01.jpg to 10.jpg and file pos.dat:

01.jpg 1 0 0 54 67

10.jpg 1 0 0 48 59

Similar in directory negative is 10 files and neg.dat :

01.jpg 1 0 0 54 67

10.jpg 1 0 0 48 59

I can create vec by:

d:\opencv\build\x86\vc10\bin\opencv_createsamples -num 10 -info positive\pos.dat -vec pos.vec -w 40 -h 40

and vec for negative:

d:\opencv\build\x86\vc10\bin\opencv_createsamples -num 10 -info negative\neg.dat -vec neg.vec -w 40 -h 40

But is error if I try opencv_traincascade.exe

d:\opencv\build\x86\vc10\bin\opencv_traincascade.exe -data dir -vec pos.vec -bg negative\neg.dat -numPos 10 -numNeg 10 -w 40 -h 40

or

d:\opencv\build\x86\vc10\bin\opencv_traincascade.exe -data dir -vec pos.vec -bg neg.vec -numPos 10 -numNeg 10 -w 40 -h 40

Is error:

Train dataset for temp stage can not be filled. Branch training terminated. Cascade classifier can't be trained. Check the used training parameters.

Is error for -bg negative\neg.dat and neg.vec, can be other?

2014-06-10 15:20:20 -0600 commented question How detect microscopic cells ?

happily not, can be grayscale; I must in first step find all cells and its kernels; next step - find only cells with big kernels

2014-06-10 10:26:43 -0600 commented question How detect microscopic cells ?

Sample detection: http://i.imgur.com/Fdp1N5g.jpg, but I must distinguish between normal and cancer cells which have bigger kernel

2014-06-10 06:50:14 -0600 asked a question How detect microscopic cells ?

I have micro image: http://slajdy.meditest.pl/ (especially second link) After zoom in are visible cells. How detect it with OpenCV? In Polish language is example link text of face detecting. How detect other shape, not only face? How train ?