Bold BI®Unlock stunning dashboards with Bold BI®: 35+ widgets, 150+ data sources, AI agent & more. Try it for free!
Hello,
I want to change an PDF to OCR.
I do it in the following way:
var appPath = Environment.CurrentDirectory + "\\OCR\\Tesseract binaries\\";
var dataPath = Environment.CurrentDirectory + "\\OCR\\tessdata\\";
using (OCRProcessor processor = new OCRProcessor(appPath))
loadedDocument.Close(true);
}
I ever get the error "Tesseract engine has not been initialized"
I have an OCR folder with the following information, which I got from the downloaded OCR setup from the SyncFusion Donwload site.
Folder OCR/Tesseract binaries:
leptonica-1.80.0.dll
libSyncfusionTesseract.dll
Folder Tessdate:
deu.traineddata
I use WPF/ Net 4.8, I compile as x64. (The Tesseract libraries are also x64).
Do I miss anything ?
Thanks and regards
Uwe
Hi Uwe Porsch,
Thank you for reaching out to Syncfusion support.
We have checked the reported issue on our end. The reported issue occurs due to Tesseract binaries are not in the required structure. While performing OCR, the binaries paths are automatically copied and default binaries path references are added in the package itself. We can also set the manual binaries path. However, we have attached the WPF sample for your reference.
Sample: https://www.syncfusion.com/downloads/support/directtrac/general/ze/OCR_Processor_WPF-1779497847
You can find the tesseract binaries and tessdata in the folder structure. "bin\Debug\runtimes\TesseractBinaries\4.0\"
Troubleshooting PDF OCR failures | Syncfusion
Kindly try the sample and let us know the result. If you are still facing the issue, we kindly request you to share the modified sample, package name, package version, and environment details (such as OS, bit version, RAM, and culture settings) to replicate the same issue on our end. This
will be more helpful for us to analyze and provide you with a prompt solution.
Regards,
Karmegm
Thanks alot, it works now.
Regards
Uwe
We are glad to hear that the issue has been resolved. please get back to us if you need any further assistance