[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Technical Report/Review ...SANE, and SANE for OCR
When Ray Ingles came to speak to us about SANE, it was about to be set up
here, with a scanner and SCSI card chosen specifically for the purpose of
aquiring images, perhaps under network control. After a couple of weeks of
tinkering, it looks like a combination of SANE, the GIMP (for post-acquisition
image processing), and some (previously acquired) OCR software (currently
running on a WIN32 box), meets or exceeds just about all of the imaging needs
'round here.
Here's an interesting kind of test....
Scan a document with different resolutions, then run the resulting image
through the OCR system and see what happens. Attached, you'll find text
that contain the results at 50, 75, 150, and 350 lines per inch. The source
text (without the formatting) is the part called "sanebase", which was proof
checked against the original hard copy, which is the handout Ray distributed
at the meeting; it's on the net (read the document, it tell you where it is).
If you are wondering why I encoded what might be considered "plain text" files,
understand that I wanted to ensure that the files I was sending would not be
altered by email gateways, translation programs, etc. Also, there may be
characters that are not printable on all platforms.
The scanner is a UMAX Astra 1200S, a SCSI scanner listed on the SANE page as
fully supported in the lastest stable release of SANE. This is a very nice
scanner, not terribly expensive, but not the cheapest, either. The SCSI card
that ships with the scanner is probably useful for something; I'm not sure if
that something has anything to do with scanners and Linux, and I was overdue
on getting a decent SCSI card, so a Buslogic 930 was invited into the house
and got plopped into a PCI slot.
SANE downloaded and compiled like a real trooper, and I got good scans on my
first try; there was no manual configuration required; either the software is
preconfigured for the scanner or it sets up in a detection phase. Documentation
is really good, too. A class act!
Problems? Two of 'em: The Buslogic card didn't seat right, so I fussed with
a few things until noticing the card was crooked, which was corrected by a
bit of gentle but firm pressure. The other problem isn't really a "problem",
it's only that SANE will require a good deal of other stuff to be loaded
so the compile goes smoothly. Load the GIMP as well as GIMP Development
stuff, X-development, and a few other things I don't remember, and then
you're off to the races! a simple make compiles EVERYTHING, so you get a
snootful of libaries in /usr/local/lib/sane, around 250K for EVERY scanner
family that is supports by SANE, totaling about just over 7Mb...but what the
heck, if you loaded GIMP and all that development stuff, wehat's another 7 Mb,
right? Someday, when I'm in a neatfreak mood, I'll cleanup everything not
needed for the SANE configuration, and say how much space I've saved. It's
also possible that I missed setting a configuration parameter that limits
compilation to a specified set of device types...
The document was scanned using SANE and xscanimage, a standard application
that ships with SANE. One can adjust the resolution desired in both X and Y
axes from nothing to the limits of the scanner hardware (in this case, 1200
lines/inch in each direction). Once the image was acquired, it was loaded
into the GIMP, which was used to redefine it as a .bmp, which was one file
format known to be a legitimate import vehicle for the OCR software. The card
in that workstation isn't the best one around here, but this is X, so throwing
xscanimage across the LAN to a machine with a REAL video card and display
was an easy, no-cost fix to THAT problem.
These files were then sent over the LAN to an NT box, which had the OCR
software that shipped with the scanner. Sometimes I'd fogotten to save the
file from the GIMP as a MONOCHROME .bmp, so there were oocasional trips into
MS "Photo Editor" or "Paint" to fix that (it didn't seem to matter where this
was done, transforms are transforms). The smallest image file was 32K,
and the largest just over 1.45 Mb.
I thought it was interesting how the OCR seems to break down COMPLETELY at 50
LPI, but is merely a noisy mess at 75. Comparing the 150 and the 350 is also
interesting stuff.... If anyone has thoughts on this, please chip in...
One item on closing: With the SANE front-end, one can vary the resolution
in both directions independently, I wonder if that would help a little...
Regards,
---> RGB <---
More SANE Resources
This Presentation
The full text of this presentation (along with all of these links) is available online at
http://www.tir.com/~sorceror/sanepres/index.htmlEach bullet point is a link to a page with explanations,
more detail, and links to further information.
The Metro Detroit Linux Users Group's home page is at http://www.mdlug.org/.
SANE Home Page
The SANE Home Page is at http://www.mostang.com/sane/. This, of course, is the most authoritative
source of SANE information. On the home page are instructions for joining the SANE mailing list,
sane-devel. The list is archived in a searchable index.
Other Relevant Links:
* Parallel Port Scanners under Linux, at http://www2.prestel.co.uk/hex/scanners.html, covers
parallel-port scanners in detail. It includes information and status on a wide variety of scanners and
support projects.
* The Linux Parallel Port Home Page, at http://www.torque.net/linux-pp.html, covers just about
everything involving Linux and the parallel port. Some information on parallel-port scanners is
included.
* The Twain Working Group home page is at http://www.twain.org/.
* Information on Linux and the QuickCam can be found at
http://www.cs.virginia.edu/~patrick/quickcam/
* The WINSANE homepage is at http://www. sunshinecomputing.com/winsane/.
sanetext50
sanetext75
sanetext150
sanetext350