Hi every one, May you please help on how to extract haar features from Mat image using java. Thanks
Below is my grayscale image.
final BufferedImage image = mnistReader.getDataAsBufferedImage(data); System.out.println(item); System.loadLibrary( Core.NATIVE_LIBRARY_NAME ); MatOpenCV temp = new MatOpenCV();
Mat tempimage = temp.matify(image);
Imgproc.threshold(tempimage, tempimage, 100, 255, Imgproc.THRESH_BINARY);
Imgproc.resize(tempimage, tempimage, new Size(6, 6));
Imgproc.cvtColor(tempimage, tempimage, Imgproc.COLOR_BGR2GRAY);