Java OCR Icon

alpha

User Ratings

★★★★★
★★★★
★★★
★★
12
2
1
0
5
ease 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5 2 / 5
features 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5 2 / 5
design 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5 2 / 5
support 1 of 5 2 of 5 3 of 5 4 of 5 5 of 5 1 / 5
Write a Review

User Reviews

  • kenjishikida
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    no one seems to care about this project. no doc, no examples

    Posted 03/12/2014
  • varun85
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Hi, I am facing issues while trying to run the JavaOCR demos. I have downloaded the source code( wasn't able to download from git, hence downloaded the SNAPSHOT version) and have maven built the source along with the demos. I can see .apk files been generated under the target directory for both javaocr-sampler and javaocr-recognizer. When I install them on my emulator, I can see the JavaOCR icons (JavaOCR Demo and JavaOCR sampler) on my emulator. But when I try to run them, I get an exception stating "Unfortunately, net.sf.javaocr.demos.android.sampler has stopped." I am not sure what is the correct order in which I need to run the demos. Please can anybody help me see what I am doing incorrectly or may be point me in the right direction. Note: I am using android-maven-plugin, version 3.6.0 and android sdk platform 19. I had to change them in order to compile the project successfully.

    Posted 02/09/2014
  • alammahtab08
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    How to run this project where is the source files . All I see is Jar files

    Posted 02/09/2014
  • devadineshkumar
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    HI team, I am facing problem that after scanning it shows only empty blank that of how many char in a row or line. I am unable to get the chars which in images. Pleas help me.

    Posted 01/21/2014
  • hdam
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Fiddled a day with OCRScannerDemo.java. Tried to train Arial-font text. Works well when I feed it the images I used for training ;p. For picures of text in the real world it didn't get anything, even if I prepocessed the images to have reasonably thresholdable characteristics. Maybe for documents perfectly photographed (pure straight text lines using black on white) this is a good lib. Otherwise I'd try tesseract (tess-two for Android of Tess4J for normal java), even though that is a nightmare to use.

    Posted 07/02/2013
  • q48vw
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    The documentation is non-existent, there are compilation errors using the library, and one of the most required methods for adding training images (getTrainingImageHashMap()) is set to private. The example code posted by Rob Cranfill two years ago is the only example set I could find, and even it doesn't work. Don't waste your time like I did with this.

    Posted 05/22/2013
  • maxbroens
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Hi guys, dont know where to post this so ill try here: For training, i use the provided example: <code> loader.load( this, trainingImageDir + "ascii.png", new CharacterRange('!', '~'), images); if (debug) System.err.println("hpljPica.jpg"); loader.load( this, trainingImageDir + "hpljPica.jpg", new CharacterRange('!', '~'), images); if (debug) System.err.println("digits.jpg"); loader.load( this, trainingImageDir + "digits.jpg", new CharacterRange('0', '9'), images); </code> i get the following error: java.io.IOException: Expected to decode 94 characters but actually decoded 95 characters in training: C:/Users/max/workspace/JavaOCR/ocrTests/trainingImages/ascii.png now, the weird part is, that when i comment out the loading of ascii.png & hpljPica.png, the loading of digits.jpg succeeds! And even works when i try to get the text from digits.jpg! now the error is created by the TrainingImageLoader.java class, method load contains: <code> (int)charValue = charRange.min; this.dest = dest; documentScanner.scan(pixelImage, this, 0, 0, 0, 0); if (charValue != (charRange.max + 1)) { throw new IOException( "Expected to decode " + ((charRange.max + 1) - charRange.min) + " characters but actually decoded " + (charValue - charRange.min) + " characters in training: " + imageFilename); } </code> so when minvalue is not equal to maxvalue+1, its gives the error. But when i print out minvalue and maxvalue of new CharacterRange('0', '9'), the only one that DOES work, i get: minvalue = 48 and maxvalue = 57 so it should give me the error to, because 48 is not equal to 57+1. But it doesnt( i'm glad to, because now i can get the text from a image containing numbers). Can someone explain to me why? And why the example code provided doesnt work? Thanks in advance!

    Posted 03/29/2013
  • ianrichardson
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Reliable and runs smoothly

    Posted 02/17/2013
  • blakenelson
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    One of the easiest apps to use

    Posted 01/23/2013
  • loganprice
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    works great.

    Posted 12/21/2012
  • adrianavalencia
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    alguien podria decirme como puedo implementarla, la verdad soy nueva en java y no se como hacerlo, gracias por su coolaboracion

    Posted 12/03/2012
  • ryanoconnor
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Easy to run javaocr

    Posted 09/20/2012
  • wacekplacek
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Excellent work.

    Posted 04/24/2012
  • jacksonbradley
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    very good program javaocr.

    Posted 03/27/2012
  • mike9090
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Fantastic library, works perfectly when I compile from the source myself. However I'm scratching my head here when trying to use the latest JAR (javaocr-20100605.zip). The TrainingImageLoader class expects a Component as the first parameter of load(). What for? I can't seem to find any JavaDocs to tell me, the latest TrainingImageLoader source (from SVN) doesn't expect this parameter.

    Posted 02/25/2012
  • imbuedhope
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    First, if you are lost I'll recommend you take a look at the performMSEOCR method in the guiController class. It's the method that does the "processing" per-se. kudos to Rob Cranfill for the code, a little bi of searching and found the method. Second, i really like this library. Although I wish i knew how to make it a bit more accurate/use more than 1 font at once. Other than that, it's great. The only working java OCR I've been able to find that doesn't have any external dependencies. If i could make a recommendation it would be the ability to use more than one font. Wonderful library, I'm using it in my sudoku solver. 4/5.

    Posted 01/02/2012
  • roncemer
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    For those complaining about documentation, first you should realize that this project is a Java LIBRARY which is intended to be used by competent SOFTWARE DEVELOPERS who are familiar with Java, and specifically the JavaDoc documentation standard and the Maven build tool. To the best of my knowledge -- and I am the original designer and author of JavaOCR -- the JavaDoc documentation is quite extensive and complete. Assuming you understand the concepts behind image-matching OCR algorithms, it should be a breeze for you to pick up the code and run with it. A good place to start is the OCRScannerDemo.java source file. This shows in detail how to train and use the JavaOCR library. This project is NOT an OCR application, but an OCR library which is both experimental and targeted toward the Java developer who is interested in the specific type of OCR which this library performs: image-matching OCR, which requires that you have exemplary images of all characters from the fonts you wish to recognize, and don't mind taking some time to write custom Java code to achieve your goals. That said, when trained for the specific printed font you wish to recognize, JavaOCR generally gives excellent recognition results, and typically outperforms more generic OCR algorithms which are targeted toward a wider variety of fonts.

    Posted 11/17/2011
  • robcranfill
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    I had no trouble using the GUI to train and analyze a simple photo of some text. I also quickly created my own code that did the same, with no UI (just a console app). Fast and easy! However, my goal is to run this on Android [as is mentioned elsewhere here - right?] but I think there's a show-stopper: JavaOCR uses AWT and ImageIO (javax.imageio, that is), neither of which are supported under Android. That said, this seems to be a quite worthwhile effort, for what it is. /rob PS - Here's a quick example of how to use this code. I created 4 training files containing images of "123456789", "ABCDE", "A" and "4", because with just the first two files, the OCR confused "A" and "4" sometimes (not surprising). The test files had "45A3" and "46B3" in them, and the code got it correct! <code> package net.robcranfill.javaocr.test; import java.awt.image.BufferedImage; import java.io.File; import java.util.ArrayList; import java.util.List; import java.util.Map; import javax.imageio.ImageIO; import net.sourceforge.javaocr.gui.GUIController; import net.sourceforge.javaocr.gui.meanSquareOCR.TrainingImageSpec; import net.sourceforge.javaocr.ocrPlugins.mseOCR.CharacterRange; import net.sourceforge.javaocr.ocrPlugins.mseOCR.OCRScanner; import net.sourceforge.javaocr.ocrPlugins.mseOCR.TrainingImage; public class Test1 { /** * @param args - unused. */ public static void main(String[] args) { new Test1().test1(); } private void test1() { // All files are here: String imageLoc = "D:/proj/_misc/JavaOCR/test1/"; // Load 4 training files List<TrainingImageSpec> images = new ArrayList<TrainingImageSpec>(0); TrainingImageSpec tis = null; tis = new TrainingImageSpec(); tis.setFileLocation(imageLoc + "1-9-Arial.png"); tis.setCharRange(new CharacterRange('1', '9')); images.add(tis); tis = new TrainingImageSpec(); tis.setFileLocation(imageLoc + "A-E-Arial.png"); tis.setCharRange(new CharacterRange('A', 'E')); images.add(tis); tis = new TrainingImageSpec(); tis.setFileLocation(imageLoc + "A-actual-small.png"); tis.setCharRange(new CharacterRange('A', 'A')); images.add(tis); tis = new TrainingImageSpec(); tis.setFileLocation(imageLoc + "4-actual-small.png"); tis.setCharRange(new CharacterRange('4', '4')); images.add(tis); // Run the OCR on our 'test' files OCRScanner ocrScanner = new OCRScanner(); try { Map<Character, List<TrainingImage>> trainingImages = GUIController.getTrainingImageHashMap(images); ocrScanner.addTrainingImages(trainingImages); // test image 1 String targImageLoc = imageLoc + "45A3-crop-rot-inv.png"; BufferedImage targetImage = ImageIO.read(new File(targImageLoc)); String text = ocrScanner.scan(targetImage, 0, 0, 0, 0, null); System.out.printf("OCR %s: '%s'\n", targImageLoc, text); // test image 2 targImageLoc = imageLoc + "46B3-crop-rot-inv.png"; targetImage = ImageIO.read(new File(targImageLoc)); text = ocrScanner.scan(targetImage, 0, 0, 0, 0, null); System.out.printf("OCR %s: '%s'\n", targImageLoc, text); } catch (Exception e) { e.printStackTrace(); } } } </code>

    Posted 10/20/2011
  • oid-3414494
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    Very poor documentation, and apparently the "support" is nonexistent.

    Posted 06/02/2011
  • shamman
    1 of 5 2 of 5 3 of 5 4 of 5 5 of 5

    I'm getting the same error when I try train. In the GUI, it isn't clear what values I am supposed to enter for starting and ending characters (A and Z did not work for the corresponding training images, didn't have any luck with ASCII values when I tried it either). A walkthrough with the GUI and some hints on using the code would be really helpful.

    Posted 01/03/2011