A lot of people seem to assume that if they get poor quality results
from Tesseract the appropriate response is to retrain tesseract. For
most cases that will just be a waste of time, and preprocessing
would be a much more sensible route.

While this is not news for those of us who have been around for very
long here, I think it could be better communicated to new users.
There is a good brief entry in the FAQ about it[0], but the FAQ is
long, and I think a more focused separate page which is referenced
from the homepage would be a better idea.

I've drafted such a page, and I'd be keen to get feedback on it. Is
it clear? Is it a good idea? I haven't filled out all of the "Image
processing" sections yet, but (presuming people don't hate the idea
in general) I will do soon, including image examples.

The page is attached, as is an image that will be displayed in the
"binarisation" section (shamelessly stolen from Zdenko's page at [1]).

Nick

0. 
http://code.google.com/p/tesseract-ocr/wiki/FAQ#Output_without_result_or_bad_output
1. http://www.sk-spell.sk.cx/through-tesseract-ocr-eye

-- 
-- 
You received this message because you are subscribed to the Google
Groups "tesseract-ocr" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/tesseract-ocr?hl=en

--- 
You received this message because you are subscribed to the Google Groups 
"tesseract-ocr" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.
= Poor quality output =

There are a variety of reasons you might not get good quality output from 
Tesseract. It's important to note that unless you're using a very unusual font 
or a new language retraining Tesseract is unlikely to help.

<wiki:toc />

== DPI ==

Tesseract works best with text using a DPI of at least 300 dpi, so it may be 
beneficial to resize images. For more information see 
[FAQ#Is_there_a_Minimum_Text_Size?_%28It_won%27t_read_screen_text!%29 the FAQ].

== Image processing ==

Tesseract does various image processing operations internally (using the 
Leptonica library) before doing the actual OCR. It generally does a very good 
job of this, but there will inevitably be cases where it isn't good enough, 
which can result in a significant reduction in accuracy.

You can see how Tesseract has processed the image by using the configuration 
variable <code>tessedit_write_images = true</code> when running Tesseract. If 
the resulting <code>tessinput.tif</code> file looks problematic, try some of 
these image processing operations before passing the image to Tesseract, either 
manually using a graphics editor like [http://www.gimp.org Gimp], or in code 
using an image processing library like [http://leptonica.com Leptonica].

=== Binarisation ===

<img style="float:right; width:50%;" src="binarisation.png" />

This is converting an image to black and white. Tesseract does this internally, 
but it can make mistakes, particularly if the page background is of uneven 
darkness.

<div style="clear:right"></div>

=== Noise ===

=== Warp ===

=== Blur / Sharpen ===

== Segmentation method ==

By default Tesseract segments an image expecting a page of text. If you're just 
seeking to OCR a small region try a different segmentation mode, using the 
<code>-psm</code> argument.

== Still having problems? ==

If you've tried the above and are still getting low accuracy results, 
[https://groups.google.com/forum/?fromgroups#!forum/tesseract-ocr ask on the 
forum] for help, ideally posting an example image.

<<attachment: binarisation.png>>

Reply via email to