Subramaniyan,

If possible, please put in a new issue 
at https://github.com/nguyenq/tess4j/issues for tracking purpose.

Thanks.

On Sunday, September 2, 2018 at 1:52:14 PM UTC-5, Quan Nguyen wrote:
>
> I tested your sample image and confirmed the error. It looks like a bug in 
> the routine that determines the image's bit depth. A new version will be 
> released once a fix is worked out and committed.
>
> Thank you for reporting.
>
> On Sunday, September 2, 2018 at 11:50:53 AM UTC-5, Subramaniyan Suresh 
> wrote:
>>
>> I am using Tess4J in my project to extract text from an image (Using 
>> Eclipse IDE). I am getting the following error when I try run the OCR. Any 
>> suggestion?  
>>
>> *Error: Exception in thread "main" java.lang.Error: Invalid memory access*
>>
>>
>> *Note: I have attached the image file which I've used *
>>
>> *My Code*:
>>
>>
>> package tesseractTraining;
>>
>>
>> import java.io.File;
>>
>> import net.sourceforge.tess4j.*;
>>
>>
>> public class TesseractMainRunner {
>>
>> public static void main(String[] args) {
>>
>> File imageFile = new File("E:\\Tesseract\\Test Images\\sample.png");
>>
>> Tesseract instance = new Tesseract();
>>
>> try {
>>
>> instance.setDatapath("C:\\Program Files (x86)\\Tesseract-OCR\\tessdata");
>>
>> instance.setLanguage("eng");
>>
>> String result = instance.doOCR(imageFile);
>>
>> System.out.println(result);
>>
>> } catch (TesseractException e) {
>>
>> System.err.println(e.getMessage());
>>
>> }
>>
>> imageFile.exists();
>>
>> }
>>
>>
>> }
>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"tesseract-ocr" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/tesseract-ocr.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tesseract-ocr/1ba5ba4c-91d9-4138-ac80-0633f43c3eab%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to