Daniel Reetz, the founder of the DIY Book Scanner community, has recently started making videos of prototyping and shop tips. If you are tinkering with a book scanner (or any other project) in your home shop, these tips will come in handy. https://www.youtube.com/channel/UCn0gq8 ... g_8K1nfInQ

Scan Tailor "Experimental"

Scan Tailor specific announcements, releases, workflows, tips, etc. NO FEATURE REQUESTS IN THIS FORUM, please.
Post Reply
Posts: 687
Joined: 03 Oct 2009, 06:13
Number of books owned: 0
Location: London, UK

Re: Scan Tailor "Experimental"

Post by Tulon » 20 Jul 2015, 09:31

dtic wrote:I'm not sure if a specific version of OpenCL is needed (1.1 , 1.2 , ... ?) or would make a difference in terms of speed.
OpenCL 1.1 is required. NVidia is dragging their feet when it comes to OpenCL support. They only introduced OpenCL 1.2 support a couple months ago, given that it was standardized back in 2011. OpenCL version doesn't affect speed, it just limits the developer in which features they can use. I generally find OpenCL 1.1 sufficient for my needs.
Scan Tailor experimental doesn't output 96 DPI images. It's just what your software shows when DPI information is missing. Usually what you get is input DPI times the resolution enhancement factor.

Posts: 41
Joined: 12 Jul 2015, 04:23
Number of books owned: 0
Country: australia

Re: Scan Tailor "Experimental"

Post by xerum » 20 Jul 2015, 09:41

dtic wrote:@Xerum, Wow those are some impressive speedup stats! Could you do a speed comparison with and without GPU (OpenCL) support?
just processed 205 scanned pages (300dpi)
i unchecked all accelerate settings and selected my onboard CPU
output process speed was 33 seconds

i then checked both accelerate settings and selected my onboard CPU
output process speed was 27 seconds

i then checked both accelerate settings and selected my GTX465 GPU
output speed was 17 seconds

however when i process the same in ST911
output speed was 2min:45sec

regardless of what accelerate settings you choose you will definitely get heaps better performance from Tulon;s STEXP

Posts: 464
Joined: 06 Mar 2010, 18:03

Re: Scan Tailor "Experimental"

Post by dtic » 20 Jul 2015, 11:11

Thanks Tulon. I realized that my Intel iGPU has OpenCL 1.2 so I can try the acceleration without a separate GPU.

Thanks Xerum. Sounds like the multithreading is the biggest factor. I'll testdrive it myself soon. Will be interesting to compare it to using multiple instances of old ST over command line. Though doubling the speed (compared to no acceleration) with your GTX465 makes me wonder what additional speed improvements one might get with a current flagship GPU (or two!).

Posts: 22
Joined: 03 Apr 2014, 21:20
E-book readers owned: 8 kindles
Number of books owned: 3000
Country: us

Re: Scan Tailor "Experimental"

Post by reproman » 20 Jul 2015, 16:30

Tulon wrote:Here is a new experimental release: https://github.com/Tulon/scantailor/rel ... 2015_07_19

This one supports multi-threaded batch processing, only the 64-bit version though.
Many thanks, 64bit works much faster.

Posts: 29
Joined: 10 Nov 2012, 17:14
Number of books owned: 0
Country: Brazil

Re: Scan Tailor "Experimental"

Post by 0kelvin » 20 Jul 2015, 21:33

I don't know if 4 threads is 4x faster than 1 thread, given that I have two cores with SMT for a total of 4 threads. But it's much like Finereader processing 4 pages at the same time, the deskew and detect text steps are now much faster.

Is there much a difference in approaching algorithm parallelization? One page on multiple threads? I have no idea about that, but for me it would be something like splitting the page in smaler pieces for each thread?

User avatar
Posts: 108
Joined: 22 Jul 2010, 18:19
Number of books owned: 1000
Country: on the net
Location: on the net

Re: Scan Tailor "Experimental"

Post by dingodog » 21 Jul 2015, 07:11

I was excited to try this new experimental branch of scantailor

but not having the qt5 libs in my linux environment I downloaded the windows executable build

the old stable branch of scantailor builds for windows worked without pain previously with wine in linux (no problems at all)

but this experimental executable for windows has some issues with wine in linux

trying to select the geometric distortion stage I get a crash.

it is mainly a wine issue, I think, I post only for information and I'll send a bug report to wine HQ

Code: Select all

Unhandled exception: unimplemented function msvcr120.dll.nextafterf called in 32-bit code (0x7b83b203).
Register dump:
 CS:0073 SS:007b DS:007b ES:007b FS:0033 GS:003b
 EIP:7b83b203 ESP:01dcd954 EBP:01dcd9c8 EFLAGS:00000212(   - --  I   -A- - )
 EAX:7b827c79 EBX:7b8a15fc ECX:00000000 EDX:01dcd980
 ESI:00000002 EDI:06bea020
Stack dump:
0x01dcd954:  01dcd9f0 00000008 00000002 00d20060
0x01dcd964:  001d4c00 01dcd9a8 80000100 00000001
0x01dcd974:  00000000 7b83b203 00000002 7ecaa4c0
0x01dcd984:  7ecae9d8 01dcd9b8 7ec69926 06bea57c
0x01dcd994:  0000031f 01dcd9c0 7eccb964 01dcda64
0x01dcd9a4:  001d4c00 01dcd9d8 7ec696cc 7eccb964
=>0 0x7b83b203 RaiseException+0x83() in kernel32 (0x01dcd9c8)
  1 0x7eca9fdf __wine_spec_unimplemented_stub+0x2e() in msvcr120 (0x01dcd9fc)
  2 0x7ec45605 __wine_stub_nextafterf+0x28() in msvcr120 (0x01dcda28)
  3 0x003694fa in dewarping (+0x394f9) (0x01dcda28)
  4 0x0036d8db in dewarping (+0x3d8da) (0x01dcda7c)
  5 0x0036b8db in dewarping (+0x3b8da) (0x01dcdb0c)
  6 0x0037c938 in dewarping (+0x4c937) (0x01dcdd18)
  7 0x0037bd94 in dewarping (+0x4bd93) (0x01dcdea0)
  8 0x0035ebd0 in dewarping (+0x2ebcf) (0x01dce23c)
  9 0x004e375d in scantailor (+0xe375c) (0x01dce454)
  10 0x004e2742 in scantailor (+0xe2741) (0x01dce4bc)
  11 0x004c5e5d in scantailor (+0xc5e5c) (0x01dce7dc)
  12 0x004c1655 in scantailor (+0xc1654) (0x01dce8f0)
  13 0x0053c12b in scantailor (+0x13c12a) (0x01dce9c4)
  14 0x005230e3 in scantailor (+0x1230e2) (0x01dce9f8)
  15 0x67026b15 in qt5core (+0x26b14) (0x01dcea4c)
  16 0x67029214 in qt5core (+0x29213) (0x00de4768)
  17 0x00de4848 (0x67233c3c)
  18 0x67208110 in qt5core (+0x20810f) (0x67208090)
  19 0x0f001879 (0x8304498b)
0x7b83b203 RaiseException+0x83 in kernel32: addl	$12,%esp
Module	Address			Debug info	Name (101 modules)
PE	  330000-  3e6000	Export          dewarping
PE	  3f0000-  400000	Deferred        zdll
PE	  400000-  6db000	Export          scantailor
PE	  6e0000-  787000	Deferred        imageproc
PE	  790000-  7b0000	Deferred        foundation
PE	  7b0000-  bf5000	Deferred        qt5gui
PE	  c00000-  c2a000	Deferred        libpng
PE	  c30000-  c6c000	Deferred        libjpeg
PE	  c70000-  ccf000	Deferred        math
PE	  cd0000-  d1d000	Deferred        libtiff
PE	  e30000-  f0c000	Deferred        qwindows
PE	10000000-10017000	Deferred        acceleration
PE	61000000-61028000	Deferred        qt5xml
PE	63000000-63046000	Deferred        qt5opengl
PE	65000000-65435000	Deferred        qt5widgets
PE	67000000-6744a000	Export          qt5core
ELF	7a800000-7a8e0000	Deferred        opengl32<elf>
  \-PE	7a820000-7a8e0000	\               opengl32
ELF	7b800000-7ba4a000	Dwarf           kernel32<elf>
  \-PE	7b810000-7ba4a000	\               kernel32
ELF	7bc00000-7bcd3000	Deferred        ntdll<elf>
  \-PE	7bc10000-7bcd3000	\               ntdll
ELF	7bf00000-7bf03000	Deferred        <wine-loader>
ELF	7d7b0000-7d7f1000	Deferred        usp10<elf>
  \-PE	7d7c0000-7d7f1000	\               usp10
ELF	7d7f2000-7d820000	Deferred        libcrypt.so.1
ELF	7d820000-7d95e000	Deferred        libcrypto.so.0
ELF	7d95e000-7d99e000	Deferred        libssl.so.0
ELF	7d99e000-7d9c6000	Deferred        libcups.so.2
ELF	7d9c6000-7da00000	Deferred        winspool<elf>
  \-PE	7d9d0000-7da00000	\               winspool
ELF	7da00000-7daec000	Deferred        comctl32<elf>
  \-PE	7da10000-7daec000	\               comctl32
ELF	7daec000-7dbcd000	Deferred        comdlg32<elf>
  \-PE	7daf0000-7dbcd000	\               comdlg32
ELF	7dbcd000-7dbe4000	Deferred        userenv<elf>
  \-PE	7dbd0000-7dbe4000	\               userenv
ELF	7e1a8000-7e1dc000	Deferred        uxtheme<elf>
  \-PE	7e1b0000-7e1dc000	\               uxtheme
ELF	7e1dc000-7e1e4000	Deferred        libxi.so.6
ELF	7e1e4000-7e201000	Deferred        wintab32<elf>
  \-PE	7e1f0000-7e201000	\               wintab32
ELF	7e249000-7e24e000	Deferred        libxfixes.so.3
ELF	7e24e000-7e257000	Deferred        libxcursor.so.1
ELF	7e257000-7e25d000	Deferred        libxrandr.so.2
ELF	7e25d000-7e265000	Deferred        libxrender.so.1
ELF	7e265000-7e26a000	Deferred        libxxf86vm.so.1
ELF	7e26a000-7e26d000	Deferred        libxinerama.so.1
ELF	7e26d000-7e272000	Deferred        libxdmcp.so.6
ELF	7e272000-7e289000	Deferred        libxcb.so.1
ELF	7e289000-7e28b000	Deferred        libxcb-xlib.so.0
ELF	7e28b000-7e28e000	Deferred        libxau.so.6
ELF	7e28e000-7e376000	Deferred        libx11.so.6
ELF	7e376000-7e384000	Deferred        libxext.so.6
ELF	7e384000-7e406000	Deferred        winex11<elf>
  \-PE	7e390000-7e406000	\               winex11
ELF	7e406000-7e50f000	Deferred        oleaut32<elf>
  \-PE	7e420000-7e50f000	\               oleaut32
ELF	7e50f000-7e535000	Deferred        msacm32<elf>
  \-PE	7e510000-7e535000	\               msacm32
ELF	7e535000-7e5e4000	Deferred        winmm<elf>
  \-PE	7e540000-7e5e4000	\               winmm
ELF	7e5e4000-7e605000	Deferred        imm32<elf>
  \-PE	7e5f0000-7e605000	\               imm32
ELF	7e60f000-7e62f000	Deferred        libexpat.so.1
ELF	7e62f000-7e65a000	Deferred        libfontconfig.so.1
ELF	7e65a000-7e66b000	Deferred        libz.so.1
ELF	7e66b000-7e6d8000	Deferred        libfreetype.so.6
ELF	7e6d8000-7e7bf000	Deferred        msvcp120<elf>
  \-PE	7e710000-7e7bf000	\               msvcp120
ELF	7e7bf000-7e7e3000	Deferred        mpr<elf>
  \-PE	7e7d0000-7e7e3000	\               mpr
ELF	7e7e3000-7e81a000	Deferred        ws2_32<elf>
  \-PE	7e7f0000-7e81a000	\               ws2_32
ELF	7e81a000-7e88f000	Deferred        rpcrt4<elf>
  \-PE	7e830000-7e88f000	\               rpcrt4
ELF	7e88f000-7e992000	Deferred        ole32<elf>
  \-PE	7e8b0000-7e992000	\               ole32
ELF	7e992000-7e9fb000	Deferred        shlwapi<elf>
  \-PE	7e9a0000-7e9fb000	\               shlwapi
ELF	7e9fb000-7ec1a000	Deferred        shell32<elf>
  \-PE	7ea10000-7ec1a000	\               shell32
ELF	7ec1a000-7ecdc000	Dwarf           msvcr120<elf>
  \-PE	7ec30000-7ecdc000	\               msvcr120
ELF	7ecdc000-7ecf4000	Deferred        version<elf>
  \-PE	7ece0000-7ecf4000	\               version
ELF	7ecf4000-7ee29000	Deferred        user32<elf>
  \-PE	7ed10000-7ee29000	\               user32
ELF	7ee29000-7ee90000	Deferred        advapi32<elf>
  \-PE	7ee40000-7ee90000	\               advapi32
ELF	7ee90000-7ef92000	Deferred        gdi32<elf>
  \-PE	7eea0000-7ef92000	\               gdi32
ELF	7efd1000-7eff8000	Deferred        libm.so.6
ELF	7eff8000-7f000000	Deferred        librt.so.1
ELF	b7bf3000-b7bfe000	Deferred        libnss_files.so.2
ELF	b7c00000-b7c04000	Deferred        libdl.so.2
ELF	b7c04000-b7d46000	Deferred        libc.so.6
ELF	b7d46000-b7d5d000	Deferred        libpthread.so.0
ELF	b7d5d000-b7f10000	Dwarf           libwine.so.1
ELF	b7f11000-b7f2e000	Deferred        ld-linux.so.2
ELF	ffffe000-fffff000	Deferred        [vdso].so
process  tid      prio (all id:s are in hex)
0000000c services.exe
	00000027    0
	00000026    0
	0000000e    0
	0000000d    0
00000024 winedevice.exe
	00000029    0
	00000028    0
	00000025    0
0000002f (D) C:\Program Files\Scan Tailor\scantailor.exe
	0000003a    0
	00000039    0
	00000038    0 <==
	00000037    0
	00000036    0
	00000030    0
00000031 explorer.exe
	00000035    0
	00000034    0
	00000033    0
	00000032    0
System information:
    Wine build: wine-1.7.47
    Platform: i386
    Host system: Linux
    Host version:

Posts: 29
Joined: 10 Nov 2012, 17:14
Number of books owned: 0
Country: Brazil

Re: Scan Tailor "Experimental"

Post by 0kelvin » 21 Jul 2015, 16:19

no features requests in this forum

Posts: 41
Joined: 12 Jul 2015, 04:23
Number of books owned: 0
Country: australia

Re: Scan Tailor "Experimental"

Post by xerum » 22 Jul 2015, 07:33

Hi Tulon,

I can't seem to get the following alignments to apply to "all pages";
- top left and right
- middle left and right
- bottom left and right

the only ones that "apply all" are;
- top middle and bottom
- centre


Posts: 13
Joined: 15 Jul 2015, 09:46
Number of books owned: 0
Country: Thailand

Re: Scan Tailor "Experimental"

Post by shinomura » 22 Jul 2015, 10:38


after test with lastest release, i think it still has output blank page bug with small content, if set alignment match size by scaling with bottom left, bottom center and bottom right. it seems glitch if set center left, center or center right.

Posts: 29
Joined: 10 Nov 2012, 17:14
Number of books owned: 0
Country: Brazil

Re: Scan Tailor "Experimental"

Post by 0kelvin » 22 Jul 2015, 13:34

I see OpenCL now. I've read that Intel i3 sandy bridge supports OpenCL 1.0 through emulation on the cpu.

Post Reply