Skip to content

Failed to initialise tesseract engine Error-1 on WebService #223

Open
@CoXmaister

Description

@CoXmaister

Hello,

I am trying to use this wrapper to create Web Service.
My problem is in initialization the engine, error is always the same I tried many different solutions.
I think that problem is in directory of tessdata folder. Adding solution for Tesseract (wrapper) to see what's the problem gave me the answer that function TessBaseAPIInit1 returns -1. I even checked in tesseract C++ repo for this function details and I came to conclusion that it returns -1 when tessdata folder is not found.

My initialization looks like this:
var engine = new TesseractEngine(@"./tessdata", "eng", EngineMode.Default) - same as in Sample

@"./tessdata" - in my program full path is C:\Program Files (x86)\IIS Express\tessdata

I copied tessdata from Sample project so there's no problem with version - I think.

So problem must be in localization of folder tessdata, I copied tessdata to folder mentioned above, and to folders in my solution (bin, debug) I insert it everywhere to be sure.

PS. Log file looks good there's no exceptions or failures, but it looks like it's not complete. Last line looks like this:
Tesseract Information: 0 : Successfully loaded native function "Te

If someone had similar problem pls help ;)

Thanks for response.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions