Apologize for my unclear expression. There are 2 tesseracts on my machine: 1. One is built from the github release (5.5.0). I use the --disable-openmp flag to conigure and I get a build without multithread.
2. I install libtesseract5 (5.3.0-2 amd64) from debian apt and the api head file is in my /usr/include folder. I compile a demo using g++ with version “gcc version 12.2.0 (Debian 12.2.0-14)”.When I run the executable file, the process use 4 threads on my machine. I find it by checking htop command results. I just tried using OpenMP to perform multithreaded recognition operations with tesseract::TessBaseAPI* (using libtesseract5), but it seems the multithreading effect has disappeared. That's weird to me. Thank you for your patience ;) 在2024年12月17日星期二 UTC-8 22:43:21<zdenop> 写道: > So you build the tesseract library without openmp, but when you use it (by > calling api) multithreading is there? > Do I understand you correctly? How did you find it out? > > Zdenko > > > st 18. 12. 2024 o 6:43 Xingtong Chen <chenxt...@gmail.com> napísal(a): > >> In tesseract document, I found that if I need to disable multithread, I >> need the configure option >> >> ../../configure --disable-openmp >> >> This works well on my machine. >> >> But I still cannot figure out how to disable multithread tesseract when >> using teseract api. >> >> I have tried -DOPENMP_SIMD_FALSE, but this didn't work. Is there any >> compile flag to disable openmp? >> >> I use g++ compiler with version "gcc version 12.2.0 (Debian 12.2.0-14)". >> >> -- >> 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 tesseract-oc...@googlegroups.com. >> To view this discussion visit >> https://groups.google.com/d/msgid/tesseract-ocr/554ec663-9411-4844-8fbf-8939c84fe594n%40googlegroups.com >> >> <https://groups.google.com/d/msgid/tesseract-ocr/554ec663-9411-4844-8fbf-8939c84fe594n%40googlegroups.com?utm_medium=email&utm_source=footer> >> . >> > -- 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 tesseract-ocr+unsubscr...@googlegroups.com. To view this discussion visit https://groups.google.com/d/msgid/tesseract-ocr/5373aed4-be1b-443d-bca2-e5888bf3d929n%40googlegroups.com.