Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Image reading breaks #424

Closed
beefeater7 opened this issue Sep 30, 2019 · 12 comments
Closed

Image reading breaks #424

beefeater7 opened this issue Sep 30, 2019 · 12 comments

Comments

@beefeater7
Copy link

beefeater7 commented Sep 30, 2019

Discovered this by processing a document of >250 pages @ 600 dpi. Exporting to PDF or ODF will trigger this. A dialogue appears after a while, telling you the image is corrupted or missing.

The dialog has an unpressable [OK] button, so you have to close it with [X], upon which the next image in line will fail to load and so on in perpetuity. The easiest way to tackle this is hold Alt+ F4.

The other way to trigger this is simply: open all the pictures, then roll through them with arrow key. Sooner or later it breaks. Once it's broken you cannot reload previous images.

Machine used was thinkpad with 4GB RAM, if it matters.

@Jossi2
Copy link

Jossi2 commented Oct 11, 2019

Same problem here with a document of 185 pages @ 400 dpi. PDF export crashes somewhere between page 037 and page 043. Tried PoDoFo and QPrinter, no difference. gImageReader 3.3.1, running in Windows 10 32 bit with 8 GB RAM, output font is Times New Roman. As the page images are OK, I suspect it runs out of memory, though I had no problems with PDF export of bigger documents before on the same machine.

@manisandro
Copy link
Owner

Sorry, missed the original report. Do you get the crash reporter showing a stack trace when gimagereader crashed? Can you share one of the documents causing the issue?

@Jossi2
Copy link

Jossi2 commented Oct 11, 2019

As the program stalls and has to be shut by force, I don't get a stack trace. I uploaded the Input files (tif), the hOCR file and the output file (PDF export) to
https://www.dropbox.com/sh/e5b7upwl0bp9gu8/AACektSxz8lBT0aH7kg6a14za?dl=0

@Jossi2
Copy link

Jossi2 commented Oct 11, 2019

Now I got a strace:
gImageReader 3.3.1 (17fa17a)

#0 0x77090941 in ntdll!DbgBreakPoint () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x770c8879 in ntdll!DbgUiRemoteBreakin () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x2c59519a in ?? ()
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 27 (Thread 4932.0x8fc):
#0 0x77090941 in ntdll!DbgBreakPoint () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x770c8879 in ntdll!DbgUiRemoteBreakin () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x2c59519a in ?? ()
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 26 (Thread 4932.0x1a10):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708cd0a in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x73d3c8a0 in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll
#3 0x6695d3ca in QWaitCondition::wait(QMutex*, unsigned long) () from C:\Program Files\gImageReader\bin\Qt5Core.dll

Thread 25 (Thread 4932.0x1a6c):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708f4fa in ntdll!ZwDelayExecution () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x73d78bfb in SleepEx () from C:\WINDOWS\System32\KernelBase.dll
#3 0x73d78b4f in Sleep () from C:\WINDOWS\System32\KernelBase.dll
#4 0x659d9460 in DUI70!?GetFlags@TouchHWNDElement@DirectUI@@QAE?AW4TouchHWNDElementFlags@2@XZ () from C:\WINDOWS\system32\dui70.dll
#5 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#6 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#7 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#8 0x00000000 in ?? ()

Thread 24 (Thread 4932.0xc88):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708cd0a in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x73d3c8a0 in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll
#3 0x6695d3ca in QWaitCondition::wait(QMutex*, unsigned long) () from C:\Program Files\gImageReader\bin\Qt5Core.dll

Thread 23 (Thread 4932.0x72c):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708cd4a in ntdll!ZwWaitForMultipleObjects () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x001637b6 in WINMM!PlaySoundW () from C:\WINDOWS\SYSTEM32\winmm.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 22 (Thread 4932.0xae4):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708cd4a in ntdll!ZwWaitForMultipleObjects () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x73d6e1a3 in WaitForMultipleObjectsEx () from C:\WINDOWS\System32\KernelBase.dll
#3 0x73d6e058 in WaitForMultipleObjects () from C:\WINDOWS\System32\KernelBase.dll
#4 0x66a6dcd6 in QWindowsFileSystemWatcherEngineThread::run() () from C:\Program Files\gImageReader\bin\Qt5Core.dll
#5 0x669564ed in QThreadPrivate::start(void*)@4 () from C:\Program Files\gImageReader\bin\Qt5Core.dll
#6 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#7 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#8 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#9 0x00000000 in ?? ()

Thread 21 (Thread 4932.0x1ae4):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 20 (Thread 4932.0xd28):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 19 (Thread 4932.0xef8):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 18 (Thread 4932.0x1b1c):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 17 (Thread 4932.0x1644):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 16 (Thread 4932.0xf0c):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 15 (Thread 4932.0x1758):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 14 (Thread 4932.0x1358):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 13 (Thread 4932.0x1e44):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 12 (Thread 4932.0x1b40):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708db5a in ntdll!ZwRemoveIoCompletion () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x7336494e in Tcpip6_WSHStringToAddress () from C:\WINDOWS\System32\mswsock.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 11 (Thread 4932.0x1378):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 10 (Thread 4932.0x3ac):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7481beda in win32u!NtUserMsgWaitForMultipleObjectsEx () from C:\WINDOWS\System32\win32u.dll
#2 0x748d245a in USER32!MsgWaitForMultipleObjectsEx () from C:\WINDOWS\System32\user32.dll
#3 0x748d2390 in USER32!MsgWaitForMultipleObjectsEx () from C:\WINDOWS\System32\user32.dll
#4 0x66b3854a in QEventDispatcherWin32::processEvents(QFlagsQEventLoop::ProcessEventsFlag) () from C:\Program Files\gImageReader\bin\Qt5Core.dll
#5 0x00000000 in ?? ()

Thread 9 (Thread 4932.0x135c):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 8 (Thread 4932.0x1af4):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708cd4a in ntdll!ZwWaitForMultipleObjects () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x73d6e1a3 in WaitForMultipleObjectsEx () from C:\WINDOWS\System32\KernelBase.dll
#3 0x74f8d24e in combase!CoDecrementMTAUsage () from C:\WINDOWS\System32\combase.dll
#4 0x74fee2ae in combase!CoInitializeSecurity () from C:\WINDOWS\System32\combase.dll
#5 0x74f8ae34 in combase!CoDecrementMTAUsage () from C:\WINDOWS\System32\combase.dll
#6 0x74f8802f in combase!RoRegisterActivationFactories () from C:\WINDOWS\System32\combase.dll
#7 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#8 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#9 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#10 0x00000000 in ?? ()

Thread 7 (Thread 4932.0x12b4):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 6 (Thread 4932.0x794):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 5 (Thread 4932.0x1824):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 4 (Thread 4932.0x1ab8):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 3 (Thread 4932.0x1bd8):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 2 (Thread 4932.0x1678):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708ccea in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x770418e6 in ntdll!TpCallbackIndependent () from C:\WINDOWS\SYSTEM32\ntdll.dll
#3 0x7548a1a4 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#4 0x7707987e in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#5 0x77079852 in ntdll!VerSetConditionMask () from C:\WINDOWS\SYSTEM32\ntdll.dll
#6 0x00000000 in ?? ()

Thread 1 (Thread 4932.0xe24):
#0 0x77090b80 in ntdll!KiFastSystemCallRet () from C:\WINDOWS\SYSTEM32\ntdll.dll
#1 0x7708cd0a in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll
#2 0x73d3c8a0 in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll
#3 0x73d3c7e2 in WaitForSingleObject () from C:\WINDOWS\System32\KernelBase.dll
#4 0x66a77fb8 in QProcessPrivate::waitForFinished(int) () from C:\Program Files\gImageReader\bin\Qt5Core.dll
#5 0x66a6fc57 in QProcess::waitForFinished(int) () from C:\Program Files\gImageReader\bin\Qt5Core.dll
#6 0x0047ec68 in qRegisterResourceData(int, unsigned char const*, unsigned char const*, unsigned char const*) ()
#7 0x004d66f4 in DTOR_LIST ()
#8 0x66c479d4 in ?? () from C:\Program Files\gImageReader\bin\Qt5Core.dll
#9 0x00424859 in MainWindow::signalHandler (signal=11) at /home/sandro/Documents/Devel/QtCreator/gimagereader/qt/src/MainWindow.cc:61
#10 0x0047f65c in _gnu_exception_handler@4 () at /usr/i686-w64-mingw32/sys-root/mingw/include/qt5/QtCore/qarraydata.h:236
#11 0x00000000 in ?? ()

@Jossi2
Copy link

Jossi2 commented Oct 29, 2019

Two additional observations: First, the size of the page images and the hOCR file together is about 260 MB. When I have loaded them both into gImageReader to make corrections, gImageReader uses about 160 MB of RAM (acccording to TaskManager). When I try to export the document as PDF and gImageReader stalls (at page 37), TaskManager shows a RAM use of about 1200 MB. Second: Although the page image TIFs were saved (in ScanTailor Advanced) with a resolution of 400 dpi (and that is also the resolution shown when opening them in a graphics application), gImageReader shows a resolution of only 100 dpi. I can neither see a reason for this change nor could I find a way to change this in gImageReader. It makes no difference if I try to export the PDF with a resolution of 100 or 400 dpi or if I set an input resolution of 100 or 400 dpi in PDF options – gImageReader crashes anyway. I went once more through the file to make sure it contains only Times New Roman as font and there are no irregularities visible in Preview. I have uploaded the new hOCR file to the dropbox folder indicated above.

@Jossi2
Copy link

Jossi2 commented Oct 30, 2019

Now I've tried to shorten the document to the first 30 pages. At first the PDF export did run through, but the resulting PDF, viewed in Adobe Acrobat Reader, showed only the OCR text level, not the page images. When I tried a second PDF export, gImageReader stalled again, this time at page 9, and again with 1300 MB RAM in use. Very strange.

@manisandro
Copy link
Owner

I've finally had time to look into this, indeed something with the image downscaling threading logic was broken. This should now be fixed.

@Jossi2
Copy link

Jossi2 commented Mar 21, 2020 via email

@tukusejssirs
Copy link

@manisandro, I believe it is either not yet fixed or not fully fixed.

I installed gIR v3.3.1 (GTK) from Fedora repos, loaded 846 images (mostly text, three simple tables + front and back covers as images). All images processed in ST Advanced and in 600 dpi. An image size is around 500 KiB, 5 images are between 1.2 and 2.9 MiB and the covers are 16 MiB and 36 MiB respectively. Altogether, their size is 251 MiB.

gIR crashes a lot, loading hOCR HTML takes some time (I have 10 GB RAM installed in this computer, 2 cores, 4 threads).

However, sometimes it works (albeit slowly). I’ve exported the PDF file, but both Evince and Adobe Acrobat Reader (both on Linux) fails to open the file and say that it is corrupted/damaged.

I have no idea how to generate a PDF file with hOCR data. I’ve read about hocr-tools package and its hocr-pdf command; and about hocr2pdf from exactImage package, but I could not make such PDF (from either image files or pre-created PDF file and from hOCR data).

@manisandro
Copy link
Owner

Without a stack trace or a reproducer, it is hard do say whether this is the same issue. The cause can also be a completely different one.

@manisandro
Copy link
Owner

Also note that this issue here affected the Qt version, so it's definitely not the same issue.

@tukusejssirs
Copy link

Thanks, @manisandro, for your reply! Should open a new issue for that, then?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants