title: Leaf vein extraction in Opencv and applying in ml
body: <p>I want to extract leaf veins and use them in machine learning process, but I don't know how to do it right.</p>
  
  <p>I've tried with sobel and get quite good results.</p>
  
  <p>code:  </p>
  
  <pre><code>  Imgproc.GaussianBlur(image, image, new Size(3, 3), 0, 0);
    Imgproc.cvtColor(image, image, Imgproc.COLOR_BGR2GRAY);      
    Mat Sx = new Mat(); Mat Sy = new Mat();
    Mat absSx = new Mat(); Mat absSy = new Mat();
    Imgproc.Sobel(image, Sx, CvType.CV_16S, 1, 0, 3, 1, 0, Imgproc.BORDER_DEFAULT);
    Core.convertScaleAbs(Sx, absSx);
    Imgproc.Sobel(image, Sy, CvType.CV_16S, 0, 1, 3, 1, 0, Imgproc.BORDER_DEFAULT);
    Core.convertScaleAbs(Sy, absSy);
    Core.addWeighted(absSx, 0.5, absSy, 0.5, 0, image);
  </code></pre>
  
  <p>images:</p>
  
  <p><a href="http://img7.imageshack.us/img7/188/16c0.jpg" rel="nofollow">1</a>
  <a href="http://img850.imageshack.us/img850/9868/auyf.jpg" rel="nofollow">2</a></p>
  
  <p>Many depends on image resolution and quality, but is there better approach?</p>
  
  <p>How to use these information in machine learning? 
  How to transform this graphical data to a form appropriate for classifiers? </p>
  
  <p>I've tried only using pixels data in classifaction, but outcome was not good.</p>