LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 10-12-2016, 06:21 AM   #1
fanoflq
Member
 
Registered: Nov 2015
Posts: 397

Rep: Reputation: Disabled
Redirecting output to console


Code:
tesseract imagename|stdin outputbase|stdout [options...] [configfile...
# this works. output is sent to outputfilename.txt
>tesseract imagename outputfilename

But how to send output to console?
Thank you.
 
Old 10-12-2016, 06:59 AM   #2
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2243Reputation: 2243Reputation: 2243Reputation: 2243Reputation: 2243Reputation: 2243Reputation: 2243Reputation: 2243Reputation: 2243Reputation: 2243Reputation: 2243
some how finagle it to send it to a tty (address)
 
Old 10-12-2016, 07:06 AM   #3
allend
LQ 5k Club
 
Registered: Oct 2003
Location: Melbourne
Distribution: Slackware64-15.0
Posts: 6,550

Rep: Reputation: 2832Reputation: 2832Reputation: 2832Reputation: 2832Reputation: 2832Reputation: 2832Reputation: 2832Reputation: 2832Reputation: 2832Reputation: 2832Reputation: 2832
You are misreading the 'man' page for tesseract.
The tesseract program can take input from either a file (imagename) or standard input (stdin), and,
send output to a file (outputbase) or your console also called standard output (stdout).
There is also a facility to optionally supply further options and/or a configuration file.
Quote:
But how to send output to console?
As shown here (note the proviso on the version of tesseract), you use:
Code:
tesseract <your input file name> stdout

Last edited by allend; 10-12-2016 at 07:07 AM.
 
1 members found this post helpful.
Old 10-12-2016, 07:57 AM   #4
fanoflq
Member
 
Registered: Nov 2015
Posts: 397

Original Poster
Rep: Reputation: Disabled
Thank you.

I thought I tried
Code:
tesseract <your input file name> stdout
and it did not worked.
now it works..... strange...
I probably made a mistake somewhere... :-(
 
Old 10-12-2016, 08:01 AM   #5
fanoflq
Member
 
Registered: Nov 2015
Posts: 397

Original Poster
Rep: Reputation: Disabled
Quote:
The tesseract program can take input from either a file (imagename) or standard input (stdin), and, .....

How do you enable tesseract to take a stdin (console) when
it is an ocr engine and needs an image like so:

Quote:
tesseract <your input file name> stdout
 
Old 10-12-2016, 08:28 AM   #6
allend
LQ 5k Club
 
Registered: Oct 2003
Location: Melbourne
Distribution: Slackware64-15.0
Posts: 6,550

Rep: Reputation: 2832Reputation: 2832Reputation: 2832Reputation: 2832Reputation: 2832Reputation: 2832Reputation: 2832Reputation: 2832Reputation: 2832Reputation: 2832Reputation: 2832
Consider a construction like
Code:
cat <your input file name> | tesseract stdin stdout
which might be useful in a script.
 
2 members found this post helpful.
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Redirecting output of 'sendmail -bv' to console linux_user2011 Linux - Server 12 05-11-2011 04:59 AM
[SOLVED] Redirecting console output from a Qt application to a telnet session bameije Linux - Embedded & Single-board computer 4 01-21-2011 09:32 AM
redirecting physical console output pwalter Linux - Newbie 3 05-13-2009 07:18 AM
Redirecting output from screen to console from boot-up ? exceed1 Linux - General 3 11-23-2008 10:26 PM
Redirecting Console MadnessASAP Linux - Software 3 10-19-2005 12:42 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 06:09 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration