PDFMaker 0.3 - help beta test!

Scan Tailor specific announcements, releases, workflows, tips, etc. NO FEATURE REQUESTS IN THIS FORUM, please.

Moderator: peterZ

User avatar
JonEP
Posts: 81
Joined: 19 Apr 2010, 15:09

Re: PDFMaker 0.2 - help beta test!

Post by JonEP »

Thanks, spamsickle.

Getting closer.

So, I tried this:

c:\pdfmaker\pdfmaker -d "C:\Users\User Name\Desktop\3 books\3a\3a crop\out"

I've substituted First Last for my user name (which consists of my first and last name with a space between)

and "out" is the folder generated by ST and containing all the tiffs.

PDF maker processed for a while, producing a scrolling feed of information in the cmd box (run as adminstrator, btw).

Finally the errors were as follows:

Code: Select all

Magick: no decode delegate for this image format `Last\Desktop\3' @ error/const
itute.c/ReadImage/532.
Magick: unable to open image `books\3a\3a': No such file or directory @ error/bl
ob.c/OpenBlob/2584.
Magick: no decode delegate for this image format `books\3a\3a' @ error/constitut
e.c/ReadImage/532.
Magick: unable to open image `crop\out\dpi.txt': No such file or directory @ err
or/blob.c/OpenBlob/2584.
Unable to open "Last\Desktop\3"Traceback (most recent call last):
  File "pdf.py", line 168, in <module>
The program seems not to be able to use names entered with a space (for instance, it brings up "Last" -- ie, my last name and the second word of my username) -- also the case for the folder named "3 books".

Should I perhaps place original images, pre- scan tailor processing, in the C: directory, using 1 word folder names, to avoid this? Or should I enter two name folder names into the command box differently (for instance "User_Name" or something like that)?

Thanks for the help.
J
User avatar
Misty
Posts: 481
Joined: 06 Nov 2009, 12:20
Number of books owned: 0
Location: Frozen Wasteland

Re: PDFMaker 0.2 - help beta test!

Post by Misty »

I'll correct the spaces issue. The AutoIt documentation had implied that spaces should be being escaped by encasing the directory in quotes, which is inaccurate.
The opinions expressed in this post are my own and do not necessarily represent those of the Canadian Museum for Human Rights.
User avatar
Misty
Posts: 481
Joined: 06 Nov 2009, 12:20
Number of books owned: 0
Location: Frozen Wasteland

Re: PDFMaker 0.2 - help beta test!

Post by Misty »

Apologies for the delay. Apparently AutoIt has one of the most unnecessary ways of escaping characters ever, but I have a space-ready version now. The ZIP also includes an updated pdf.py which has a fix for the DPI issue. It's currently hardcoded to 600, which is better than being hardcoded to 72, but I can make a version that isn't hardcoded if anyone needs that.

I've also seen the PDFBeads software mentioned which does much the same thing as PDFMaker, with an OCR option. I haven't used it myself yet, though.
Attachments
pdfmaker 0.3.zip
PDFMaker 0.3
(6.37 MiB) Downloaded 683 times
The opinions expressed in this post are my own and do not necessarily represent those of the Canadian Museum for Human Rights.
User avatar
JonEP
Posts: 81
Joined: 19 Apr 2010, 15:09

Re: PDFMaker 0.3 - help beta test!

Post by JonEP »

It works!

Very nice. Thank you so much.
User avatar
JonEP
Posts: 81
Joined: 19 Apr 2010, 15:09

Re: PDFMaker 0.3 - help beta test!

Post by JonEP »

By the way, even though the program is outputting perfectly usable pdfs, for the most part, at the close of using it I do receive a series of error messages, along these lines:

Code: Select all

TIFFFetchDirectory: TIFFstream: Can not read TIFF directory.
TIFFReadDirectory: TIFFstream: Failed to read directory at offset 0.
Error in findTiffCompression: tif not opened
JBIG2 compression complete. pages:1 symbols:541 log2:10
TIFFFetchDirectory: TIFFstream: Can not read TIFF directory.
TIFFReadDirectory: TIFFstream: Failed to read directory at offset 0.
Error in findTiffCompression: tif not opened
JBIG2 compression complete. pages:1 symbols:451 log2:9
TIFFFetchDirectory: TIFFstream: Can not read TIFF directory.
TIFFReadDirectory: TIFFstream: Failed to read directory at offset 0.
Error in findTiffCompression: tif not opened
JBIG2 compression complete. pages:1 symbols:657 log2:10
TIFFFetchDirectory: TIFFstream: Can not read TIFF directory.
TIFFReadDirectory: TIFFstream: Failed to read directory at offset 0.
Error in findTiffCompression: tif not opened
JBIG2 compression complete. pages:1 symbols:1518 log2:11
 done
Running ImageMagick... done
Running pdftk... done!
All done! Finished processing files.
Not sure what that all means, but so far so good in terms of creating smaller pdfs from the scan tailor output. Thanks for your work,
Jon
User avatar
Misty
Posts: 481
Joined: 06 Nov 2009, 12:20
Number of books owned: 0
Location: Frozen Wasteland

Re: PDFMaker 0.3 - help beta test!

Post by Misty »

Sorry, I should have warned about that. That's a jbig2enc bug. The errors are completely meaningless - it's opening the TIFFs fine despite the errors. If you'd rather be rid of them, you can download an older version of jbig2enc for Windows and it should work okay without the errors.
The opinions expressed in this post are my own and do not necessarily represent those of the Canadian Museum for Human Rights.
User avatar
Misty
Posts: 481
Joined: 06 Nov 2009, 12:20
Number of books owned: 0
Location: Frozen Wasteland

Re: PDFMaker 0.3 - help beta test!

Post by Misty »

Since PDFMaker seems to be reaching some kind of stable state, I thought I should post the source code - ugly as it is. Someone might find it useful.
Attachments
PDFMaker 0.3 src.zip
(701 Bytes) Downloaded 594 times
The opinions expressed in this post are my own and do not necessarily represent those of the Canadian Museum for Human Rights.
User avatar
Misty
Posts: 481
Joined: 06 Nov 2009, 12:20
Number of books owned: 0
Location: Frozen Wasteland

Re: PDFMaker 0.3 - help beta test!

Post by Misty »

I noticed the "bin" package only includes a compiled version of pdf.py. Here's the source to the version being used, for reference.
Attachments
pdf.zip
(1.9 KiB) Downloaded 561 times
The opinions expressed in this post are my own and do not necessarily represent those of the Canadian Museum for Human Rights.
User avatar
JonEP
Posts: 81
Joined: 19 Apr 2010, 15:09

Re: PDFMaker 0.3 - help beta test!

Post by JonEP »

Hi,

I've been using this for a few weeks now, and all runs smoothly with one exception. For each session, the script generates between 4 and 12 or so blank PDFs, of 0kb of size. In each of these cases it also generates a tif file in the folder out > pic, ie.: 0034.sep.tif, 0035.sep.tif, etc. I don't see a problem with the TIF output by Scan Tailor (there is text visible)... Any ideas of how to deal with this?

Thanks.
User avatar
JonEP
Posts: 81
Joined: 19 Apr 2010, 15:09

Re: PDFMaker 0.3 - help beta test!

Post by JonEP »

I'm now getting errors (like those described in my last post) for every page when I use PDFMaker. Is it possible that upgrading the version of ScanTailor has created this problem?
Thanks,
Jon
Post Reply