diff --git a/File-Formats/PDF/Working-with-OCR/Troubleshooting.md b/File-Formats/PDF/Working-with-OCR/Troubleshooting.md index 3fad7b8a1..c3accda84 100644 --- a/File-Formats/PDF/Working-with-OCR/Troubleshooting.md +++ b/File-Formats/PDF/Working-with-OCR/Troubleshooting.md @@ -180,7 +180,7 @@ By using the best tessdata, we can improve the OCR results. For more information To resolve this problem, you should install and utilize Tesseract 5 on your Mac machine. Refer to the following steps for installing Tesseract 5 and integrating it into an OCR processing workflow.

-1.Execute the following command to install Tesserat 5. +1.Execute the following command to install Tesseract 5.

{% tabs %} {% highlight C# %} @@ -356,6 +356,56 @@ Step 3: {% endhighlight %} {% endtabs %} + + + + +## OCR not working on Docker net 8.0: Exception has been thrown by target of an invocation. + + + + + + + + + + +
ExceptionOCR not working on Docker net 8.0: Exception has been thrown by target of an invocation.
Reason +The reported issue occurs due to the missing prerequisite dependencies packages in the Docker container in .NET 8.0 version. +
Solution + We can resolve the reported issue by installing the tesseract required dependencies by using Docker file. Please refer the below commands. + +{% tabs %} + +{% highlight C# %} + +FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS base + +`RUN apt-get update && \` + +`apt-get install -yq --no-install-recommends \` + +`libgdiplus libc6-dev libleptonica-dev libjpeg62` + +`RUN ln -s /usr/lib/x86_64-linux-gnu/libtiff.so.6 /usr/lib/x86_64-linux-gnu/libtiff.so.5` + +`RUN ln -s /lib/x86_64-linux-gnu/libdl.so.2 /usr/lib/x86_64-linux-gnu/libdl.so` + + + +USER app + +WORKDIR /app + +EXPOSE 8080 + +EXPOSE 8081 + +{% endhighlight %} + +{% endtabs %} +
\ No newline at end of file