Java OCR standalone

  • 1.5K Views
  • Last Post 19 May 2015
Jacopo Interbartolo posted this 11 May 2015

Hi, I'm trying to do an ocr on java for a standalone project. I have already builded on eclipse the project on https://github.com/abbyysdk/ocrsdk.com/tree/master/Java/Abbyy.Ocrsdk.client. How can i add an image on this project and have the output on java? Thank you

Oksana Serdyuk posted this 19 May 2015

Please sorry for delay in response.

After you have built the project, you can run it from the command line (Start -> Run -> type “cmd” and press Enter). Change the current directory to the bin folder where the TestApp.class file is, so that Java can find the main class (for example, C:\Java\Abbyy.Ocrsdk.client\bin). Now you can run the Java sample using one of the supported modes:

1) To process single- and multipage documents and convert them to txt, xml, pdf and other formats, use:

  java TestApp recognize testImage.jpg result.xml
  java TestApp recognize page1.jpg page2.jpg page3.jpg result.pdf --lang=French,Spanish

2) To process business cards to vCard, xml and csv, use:

java TestApp busCard image.jpg result.xml

3) To process printed and handprinted text snippets, use:

  java TestApp textField image.jpg result.xml

4) To recognize barcodes, use:

 java TestApp barcode image.jpg result.xml

5) To process many different snippets on document, use:

 java TestApp processFields image1.jpg image2.jpg image3.tif settings.xml result.xml

6) For MRZ processing use:

java TestApp MRZ image.jpg result.xml

Close