@Matt: I downloaded v3.01 and running with cmd line on inverted image, i do
not get output as per your changes. Is this change available in the current
installer?
On Thursday, September 22, 2011 2:48:56 AM UTC-4, ogorman wrote:
>
> A few months ago I was having trouble with getting osd working in
> 3.0.1. And I wanted to post that this is now fixed and easy to
> setup. I did the following.
>
> svn checkout trunk which is currently rev626
> ./runautoconf
> ./configure
> comment out the line
> libtesseract_la_OBJECTS = libtesseract.lo
> in the Makefile, on mine it was line 87. If you don't do this you can
> not build tesseract at least on my machine. I also made the following
> change in osdetect so I can tell when an image was read upside down or
> rightside up and make changes to my documents that I will display to
> the user in my system.
> Index: ccmain/osdetect.cpp
> ===================================================================
> --- ccmain/osdetect.cpp (revision 626)
> +++ ccmain/osdetect.cpp (working copy)
> @@ -269,6 +269,7 @@
>
> // Make sure the best_result is up-to-date
> int orientation = o.get_orientation();
> + printf("orientation %d\n", orientation);
> osr->update_best_script(orientation);
> return num_blobs_evaluated;
> }
>
>
> so once you have the changes done
> make ; make install
> cp ${WHERE_YOU_INSTALLED}/tessdata/eng.traineddata $
> {WHERE_YOU_INSTALLED}/tessdata/osd.traineddata
> finally you can run this command
> tesseract /tmp/test2.tif /tmp/outputfile -psm 1
> which will give you output like this
> Tesseract Open Source OCR Engine v3.01 with Leptonica
> Page 0
> orientation 2
> 2 if the page is upside down 0 if its right side up.
>
> I hope this helps people use this great project.
>
> Matt
--
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