Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Formats > Other formats > IMP

Notices

Reply
 
Thread Tools Search this Thread
Old 04-01-2007, 02:23 AM   #16
sputnik
Enthusiast
sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.
 
sputnik's Avatar
 
Posts: 46
Karma: 133388
Join Date: Mar 2007
Location: London, Ontario
Device: EB 1150, iLiad
I did what you said and it is amazing. I like the landscape orientation better. I just converted a pdf image (scanned text) file and I almost prefer the quality to that of the normal imp files. This piece of soft is really great for me, since I read lots of pdf files which consist of scanned text images. Congratulations!
sputnik is offline   Reply With Quote
Old 04-01-2007, 02:37 AM   #17
ashkulz
Addict
ashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enough
 
ashkulz's Avatar
 
Posts: 350
Karma: 705
Join Date: Dec 2006
Location: Mumbai, India
Device: Kindle 1/REB 1200
Quote:
Originally Posted by sputnik
I did what you said and it is amazing. I like the landscape orientation better. I just converted a pdf image (scanned text) file and I almost prefer the quality to that of the normal imp files. This piece of soft is really great for me, since I read lots of pdf files which consist of scanned text images. Congratulations!
Thanks, I added how to workaround this issue in the main post. I also love the ability to read PDFs -- I have a lot of good reading material, and going the PDF -> HTML route was just too much effort (especially for books with complex layouts).
ashkulz is offline   Reply With Quote
Advert
Old 04-01-2007, 06:53 AM   #18
ashkulz
Addict
ashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enough
 
ashkulz's Avatar
 
Posts: 350
Karma: 705
Join Date: Dec 2006
Location: Mumbai, India
Device: Kindle 1/REB 1200
Okay, the bug which was discovered by sputnik has been fixed and support for IMP format has been added.

For the IMP format support, please install the eBook Publisher from Ebook Technologies. Also note that imp1 = Color VGA (1200) and that imp2 = Grayscale Half-VGA (1150), similiar to their ETI-1 and ETI-2 designations. Also note that the IMP format support works only on Windows.
ashkulz is offline   Reply With Quote
Old 04-02-2007, 03:24 PM   #19
obelix
Connoisseur
obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.
 
Posts: 65
Karma: 1695
Join Date: Oct 2006
Quote:
Originally Posted by ashkulz
Did you try that workaround I mentioned? The crash comments were directed to obleix, not you. Scroll up to see the workaround.

I will release a new version on monday with the fix and IMP format support.
The problem gone with the fix.
Great program, thank you very much.
PDF A4 are readble now on PRS-500. Inrerface is very simple and GUI'ed what makes this program much easy to use than PDFrasterFarian with about the same image quality.

Some notes:

PDF (portrait orientation) is smaller than screen size, it looks like the right and the bottom fields are not cropped. Actually, I think the PRS-500 image size is not correct rather than lack of cropping. It can be seen from the following, for 3 zoom settings:

1. At small size: Portrait PDF is alligned to the top and left, right and bottom margins are about 20% of the screen size.
2. At middle size. Image gets larger, but right and bottom margins still exist.
3. At the highest zoom. Image gets larger than the sceen size, right and bottom parts are out of the scope.

Please check if the image size is set exactly to the screen size: 584х754
(not 600x800 !!!) Reader is very sensitive to the proper screen size.
obelix is offline   Reply With Quote
Old 04-02-2007, 11:27 PM   #20
ashkulz
Addict
ashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enough
 
ashkulz's Avatar
 
Posts: 350
Karma: 705
Join Date: Dec 2006
Location: Mumbai, India
Device: Kindle 1/REB 1200
Quote:
Originally Posted by obelix
PDF (portrait orientation) is smaller than screen size, it looks like the right and the bottom fields are not cropped. Actually, I think the PRS-500 image size is not correct rather than lack of cropping. It can be seen from the following, for 3 zoom settings:

1. At small size: Portrait PDF is alligned to the top and left, right and bottom margins are about 20% of the screen size.
2. At middle size. Image gets larger, but right and bottom margins still exist.
3. At the highest zoom. Image gets larger than the sceen size, right and bottom parts are out of the scope.

Please check if the image size is set exactly to the screen size: 584х754
(not 600x800 !!!) Reader is very sensitive to the proper screen size.
Well, I guess you're right. According to the info I had, I used the following settings:
Code:
Default options for the profile prs500:
  rotate=none hres=565 format=lrf vres=754 nosplit=True colors=4

Default options for the profile prs500-l:
  rotate=left hres=754 format=lrf vres=565 overlap=45 colors=4
Should I change that to 584 instead of 565? I simply kept what was the default in PDFRasterFarian, which sets it to 565. Can you try running the following in a command prompt and let me know if the output looks OK?
Code:
<installdir>\pdfread-run.cmd -p prs500 --hres 584 <pdf-file>
I'll be adding some form of "custom" profile via the GUI sometime soon, as time permits :-)
ashkulz is offline   Reply With Quote
Advert
Old 04-03-2007, 01:27 AM   #21
obelix
Connoisseur
obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.obelix once ate a cherry pie in a record 7 seconds.
 
Posts: 65
Karma: 1695
Join Date: Oct 2006
Quote:
Originally Posted by ashkulz
Well, I guess you're right. According to the info I had, I used the following settings:
Code:
Default options for the profile prs500:
  rotate=none hres=565 format=lrf vres=754 nosplit=True colors=4

Default options for the profile prs500-l:
  rotate=left hres=754 format=lrf vres=565 overlap=45 colors=4
Should I change that to 584 instead of 565? I simply kept what was the default in PDFRasterFarian, which sets it to 565. Can you try running the following in a command prompt and let me know if the output looks OK?
Code:
<installdir>\pdfread-run.cmd -p prs500 --hres 584 <pdf-file>
I'll be adding some form of "custom" profile via the GUI sometime soon, as time permits :-)
Nothing has changed.

1. The PNG images for pages are 497x754 (with slight variation of width for each of the pages)
2. In the LRS file:

"<ImageBlock blockheight="768" blockwidth="600" objid="3" objlabel="ImageBlock.3" refstream="13" x0="0" x1="600" xsize="565" y0="0" y1="800" ysize="754"/>"

i.e xsize is still 565, but this is not that important.

I was not right, you can use 600x800 (in contrast to the text its not very important).

Now I figured out whats happening (looking at the actual image size): To keep proportionality of the page, the program adjust one of the png image sizes (754), the other one is selected to maintain aspect ratio (497). Nothing can be done. My sample has this aspect ratio. The only improvement (I'm not sure if somebody really care) the image can be centered with "<BlockSpace xspace= yspace= ".

So there is no problem, my mistake. Thanks again for great program.
obelix is offline   Reply With Quote
Old 04-03-2007, 05:15 AM   #22
ashkulz
Addict
ashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enough
 
ashkulz's Avatar
 
Posts: 350
Karma: 705
Join Date: Dec 2006
Location: Mumbai, India
Device: Kindle 1/REB 1200
Quote:
"<ImageBlock blockheight="768" blockwidth="600" objid="3" objlabel="ImageBlock.3" refstream="13" x0="0" x1="600" xsize="565" y0="0" y1="800" ysize="754"/>"

i.e xsize is still 565, but this is not that important.

I was not right, you can use 600x800 (in contrast to the text its not very important).
Yeah, I forgot -- I hard coded that 565 in the code, will fix that soon.

BTW, can you really use the full 600x800? I would imagine that some pixels would be taken by the user interface... please let me know what is the biggest size which is not cropped by the reader, as I don't have a reader to actually test it out.

Quote:
Now I figured out whats happening (looking at the actual image size): To keep proportionality of the page, the program adjust one of the png image sizes (754), the other one is selected to maintain aspect ratio (497). Nothing can be done. My sample has this aspect ratio. The only improvement (I'm not sure if somebody really care) the image can be centered with "<BlockSpace xspace= yspace= ".

So there is no problem, my mistake. Thanks again for great program.
Yes, I forgot to mention that in the release notes. One of the ideas that I initially took from PDFRasterFarian but really annoyed me (and hence changed) is that if you do agressive cropping, and your page has only one paragraph, that whole paragraph fits the whole page (with the letters being really tall). So I took care to maintain the aspect ratio, as it is a slippery slope to decide when to respect it and when to forget it. I do a lot of calculations to find the optimal width and height.

Also, I'd suggest that you try the landscape mode once (prs-500l) -- I would expect it would look as good as a real PDF printout, however with lesser text per page.
ashkulz is offline   Reply With Quote
Old 04-03-2007, 06:41 AM   #23
sammykrupa
Reader of the Reader
sammykrupa doesn't littersammykrupa doesn't litter
 
Posts: 103
Karma: 107
Join Date: Apr 2006
Device: Sony Reader PRS-500
When I tried to run PDFRead on my Mac (after installing all of the dependencies) I get this:

Traceback (most recent call last): File "src/pdfread.py", line 51, in ?
import os, sys, re, subprocess, Image, ImageFilter, ImageChops, optparse, shutil, traceback
ImportError: No module named subprocess

Thanks for the work done so far!

But what's up here?

Sam Krupa
sammykrupa is offline   Reply With Quote
Old 04-03-2007, 07:26 AM   #24
ashkulz
Addict
ashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enough
 
ashkulz's Avatar
 
Posts: 350
Karma: 705
Join Date: Dec 2006
Location: Mumbai, India
Device: Kindle 1/REB 1200
Quote:
When I tried to run PDFRead on my Mac (after installing all of the dependencies) I get this:

Traceback (most recent call last): File "src/pdfread.py", line 51, in ?
import os, sys, re, subprocess, Image, ImageFilter, ImageChops, optparse, shutil, traceback
ImportError: No module named subprocess
Please check that you are using python 2.4 or later (You can find the current version by running "python -V"). If you're using 2.3 or lower, you can dowload the missing subprocess module (which was introduced in 2.4), save it as subprocess.py in the same directory as pdfread.py, and try again.

Last edited by ashkulz; 04-03-2007 at 07:29 AM. Reason: edited link to point to the python svn
ashkulz is offline   Reply With Quote
Old 04-03-2007, 05:37 PM   #25
sammykrupa
Reader of the Reader
sammykrupa doesn't littersammykrupa doesn't litter
 
Posts: 103
Karma: 107
Join Date: Apr 2006
Device: Sony Reader PRS-500
New error:

Traceback (most recent call last):
File "src/pdfread.py", line 51, in ?
import os, sys, re, subprocess, Image, ImageFilter, ImageChops, optparse, shutil, traceback
ImportError: No module named Image


Should I just upgrade to 2.4?

Or is it something deeper?

Sam Krupa
sammykrupa is offline   Reply With Quote
Old 04-03-2007, 05:48 PM   #26
sammykrupa
Reader of the Reader
sammykrupa doesn't littersammykrupa doesn't litter
 
Posts: 103
Karma: 107
Join Date: Apr 2006
Device: Sony Reader PRS-500
Update:
Okay, got pass those Image errors. Figured those had to do with PIL. Reinstalled it and I got a little farther this time:

Unable to determine total number of pages in PDF
Please enter total page count: 3

Temporary directory: /tmp/pdfread-oDxOLM

Page 1/3: EXTRACT RASTERIZE BLANK
Page 2/3: EXTRACT RASTERIZE BLANK
Page 3/3: EXTRACT RASTERIZE BLANK
Traceback (most recent call last):
File "/Users/mikekrup/Desktop/pdfread-v4-src/src/pdfread.py", line 515, in ?
PdfConverter().main()
File "/Users/mikekrup/Desktop/pdfread-v4-src/src/pdfread.py", line 338, in main
delete = self.FORMATS[self.options.format](self)
File "/Users/mikekrup/Desktop/pdfread-v4-src/src/pdfread.py", line 279, in generate_lrf
from pylrs.pylrs import Book, PageStyle, BlockStyle, ImageStream, BlockSpace, ImageBlock
File "/Users/mikekrup/Desktop/pdfread-v4-src/src/pylrs/pylrs.py", line 11
from elementtree.ElementTree import (Element, SubElement)
^
SyntaxError: invalid syntax

-------------------------
So close!
Seems to be a problem with PDFs on Mac OS X?

Sam Krupa
sammykrupa is offline   Reply With Quote
Old 04-03-2007, 11:24 PM   #27
ashkulz
Addict
ashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enoughashkulz will become famous soon enough
 
ashkulz's Avatar
 
Posts: 350
Karma: 705
Join Date: Dec 2006
Location: Mumbai, India
Device: Kindle 1/REB 1200
Quote:
Originally Posted by sammykrupa
Unable to determine total number of pages in PDF
Please enter total page count: 3

Temporary directory: /tmp/pdfread-oDxOLM

Page 1/3: EXTRACT RASTERIZE BLANK
Page 2/3: EXTRACT RASTERIZE BLANK
Page 3/3: EXTRACT RASTERIZE BLANK
Traceback (most recent call last):
File "/Users/mikekrup/Desktop/pdfread-v4-src/src/pdfread.py", line 515, in ?
PdfConverter().main()
File "/Users/mikekrup/Desktop/pdfread-v4-src/src/pdfread.py", line 338, in main
delete = self.FORMATS[self.options.format](self)
File "/Users/mikekrup/Desktop/pdfread-v4-src/src/pdfread.py", line 279, in generate_lrf
from pylrs.pylrs import Book, PageStyle, BlockStyle, ImageStream, BlockSpace, ImageBlock
File "/Users/mikekrup/Desktop/pdfread-v4-src/src/pylrs/pylrs.py", line 11
from elementtree.ElementTree import (Element, SubElement)
^
SyntaxError: invalid syntax
Okay, there some to be two errors here:
  • All the PDF pages were detected as blank. This is not normal, as that means GhostScript did not produce the PNG file. Go to the temporary directory mentioned, and see if any png images are present. If not, change line 122 and add "print " before exec_cmd and paste the output here. The code should look like:
    Code:
    print exec_cmd('gs', '-q', ...
  • You also need the elementtree module (this is included in python 2.5) -- download the ElementTree library, extract it and copy the folder 'elementtree' to the same location as pdfread.py

BTW, once you get it working, could you post the steps you took to install everything? I'm sure it would be of interest to other people who use OS X.
ashkulz is offline   Reply With Quote
Old 04-04-2007, 01:39 AM   #28
sputnik
Enthusiast
sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.sputnik puts his or her pants on both legs at a time.
 
sputnik's Avatar
 
Posts: 46
Karma: 133388
Join Date: Mar 2007
Location: London, Ontario
Device: EB 1150, iLiad
cropping problem?

Well, it is not really a cropping problem in itself. As one can see here, the png's look just fine. However, when I open the imp file (either on EB-1150 or on the computer) the scroll bar of the EB-1150 at the bottom of the screen overlaps a little bit with the image and the first letters of the words in the text cannot be seen.

Also, in some pages, the last line of text in the page is being "cut" by the crop, and becomes completely illegible, as one can see here . One possible solution that I can see is to crop the pages so that the bottom of one page would overlap with the top of the next page. In case the text is being cropped and the last line is illegible, this solution would allow one to read the line in question on the next page. Of course, this would probably generate some redundancies, but it's preferable to have the same line of text twice than not to have it at all.

Last edited by sputnik; 04-04-2007 at 01:43 AM.
sputnik is offline   Reply With Quote
Old 04-04-2007, 07:07 AM   #29
sammykrupa
Reader of the Reader
sammykrupa doesn't littersammykrupa doesn't litter
 
Posts: 103
Karma: 107
Join Date: Apr 2006
Device: Sony Reader PRS-500
Okay, I am messing up horribly now. I put the 'elementtree' folder in with the pdfread.py file, and that didn't make those "Element" warnings go away.

Also, there were no PNG files in the temp directory. And I couldn't figure out how to make that change in the code, I keep getting weird errors. It would probably be best for you to upload the changed code for me to try.

Sorry to bother you with this!
Sam Krupa
sammykrupa is offline   Reply With Quote
Old 04-04-2007, 01:13 PM   #30
kgian
Enthusiast
kgian began at the beginning.
 
Posts: 31
Karma: 10
Join Date: Apr 2007
Device: EBW-1150
Software seems great but has some bugs still. I am trying to convert the sample pdf file you posted in your first post and I get the following outpout. It creates the png files and stops there, not creating the actual imp file. I have a ebw 1150 and have selected eb1150 in the options.
I have ebook publisher installed. Maybe I should uninstall it and install it again after the pdfread software?

"Temporary directory: c:\docume~1\gianno~1\locals~1\temp\pdfread-ss_ddu

Page 1/5: EXTRACT RASTERIZE CROP DILATE RESIZE SPLIT DONE
Page 2/5: EXTRACT RASTERIZE CROP DILATE RESIZE SPLIT DONE
Page 3/5: EXTRACT RASTERIZE CROP DILATE RESIZE SPLIT DONE
Page 4/5: EXTRACT RASTERIZE CROP DILATE RESIZE SPLIT DONE
Page 5/5: EXTRACT RASTERIZE CROP DILATE RESIZE SPLIT DONE

Creating IMP file ... failed, error details follow.

Traceback (most recent call last):
File "pdfread.py", line 365, in generate_imp
File "win32com\gen_py\1103EA00-3A0C-11D3-A6F6-00104B2947FBx0x1x0.pyo", line 11
42, in NewUniqueID
com_error: (-2147352573, 'Member not found.', None, None)

Output directory: c:\docume~1\gianno~1\locals~1\temp\pdfread-ss_ddu

Press any key to continue . . .
"

Actually that was it, you have to reinstall Ebook Publisher AFTER you install pdfread.
Works great now!

Last edited by kgian; 04-04-2007 at 01:19 PM.
kgian is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
In addition to your eBookwise 1150, how many also own different ebook readers? nrapallo Fictionwise eBookwise 40 04-07-2009 10:13 AM
Comparing 1150 to 1200 or 2150 Katelyn Fictionwise eBookwise 1 04-29-2007 11:38 AM
PDFRead - reading PDFs on eBook Readers ashkulz Sony Reader 19 04-29-2007 11:28 AM
eBookwise-1150 or older Palm for ebook reading Katelyn Fictionwise eBookwise 5 11-22-2006 08:32 PM


All times are GMT -4. The time now is 07:16 AM.


MobileRead.com is a privately owned, operated and funded community.