Why aren't Tesseract and GhostScript recognized as commands? - command-line

I have a large batch of PDFs that I can't OCR because they've each got a small field of renderable text.
I'm trying to convert them all to TIFF so I can convert back and run OCR, but I'm running into problems invoking the programs that I'd expect to do the job. I installed them without issue, but for some reason, I keep getting errors saying the associated commands don't exist:
c:\Program Files\Python37\Lib\site-packages>pip install tesseract
Requirement already satisfied: tesseract in c:\program files\python37\lib\site-packages (0.1.3)
c:\Program Files\Python37\Lib\site-packages>tesseract --version
'tesseract' is not recognized as an internal or external command,
operable program or batch file.
c:\Program Files\Python37\Lib\site-packages>pip install ghostscript
Requirement already satisfied: ghostscript in c:\program files\python37\lib\site-packages (0.6)
Requirement already satisfied: setuptools in c:\program files\python37\lib\site-packages (from ghostscript) (40.8.0)
c:\Program Files\Python37\Lib\site-packages>gs --version
'gs' is not recognized as an internal or external command,
operable program or batch file.
c:\Program Files\Python37\Lib\site-packages>gswin32c --version
'gswin32c' is not recognized as an internal or external command,
operable program or batch file.
Any ideas what I'm doing wrong?
Bonus points if you've got a better way to perform the overall task.

I notice you are using Windows, I would guess that you haev not added the Ghostscript install directory to the $PATH environment variable, and so Windows does not know where to look to find the executable.
It may be that Python can use the Ghostscript executable from the python37\lib\site-packages directory, but Windows won't know that unless its been told to look there. It'll probably be a sub-directory, unless the Python package installer uses something other than the normal Ghostscript Windows installer.
Note that on Windows the binary is not called 'gs'; it will be either gswin32, gswin64, gswin32c or gswin64c depending on whether you installed the 32 or 64-bit version of Ghostscript, and whether you want the command line (c) or windowed version.
Probably the easiest way to find it is to look in the specified Python folder and see.

Related

ISCC.exe not found in powershell [duplicate]

I am trying to turn an Inno .iss file to the installer .exe over the command line.
I have found this page on the Inno website which shows you how to do this:
http://www.jrsoftware.org/ishelp/index.php?topic=setupcmdline
When I tried these commands, I got the command not found error:
'compil32' is not recognized as an internal or external command,
operable program or batch file.
I got the same error when trying iscc instead of compil32. I also tried compil64, as my computer is 64 bit, with the same result.
Thanks in advance.
This is basic operating system functionality. You need to either put the directories where the Inno Setup binaries are located into your system PATH, or use a fully qualified pathname to the executables when running them.

'raco' is not recognized on the windows 10 command line

I'm trying to get familiar with DrRacket plugin framework, and I'm using the following tutorial:
https://lang.video/blog/2018/03/21/making-an-ide-plugin-for-drracket/
I'm stuck at the step where raco is used:
When i run the command, my windows 10 operating system gives back the following error message, How can i solve this?:
'raco' is not recognized as an internal or external command,
operable program or batch file.
second question:
I've also tried putting the clippy folder into a folder within my program files, in the DrRacket installation. Is this the location where Racket Plugins should reside, or can they be placed in any folder?
Add racket and raco to your Windows PATH (the directories in which Windows looks for commands).
https://beautifulracket.com/setting-the-windows-path.html

How to install avconv on windows 10?

I am working on matlab R2017a. For my project, I have to install avconv. I have searched a lot, but I only find a useful link that is this. After installing it, I run setup.exe, add following path to environment variables that is
C:\Program Files\AVCONV
After I execute my file, and it shows the same error that is this:
'avconv' is not recognized as an internal or external command,
operable program or batch file
I spent time on this, trying different solution, but found no useful help.

Compiling inno .iss file with the command line

I am trying to turn an Inno .iss file to the installer .exe over the command line.
I have found this page on the Inno website which shows you how to do this:
http://www.jrsoftware.org/ishelp/index.php?topic=setupcmdline
When I tried these commands, I got the command not found error:
'compil32' is not recognized as an internal or external command,
operable program or batch file.
I got the same error when trying iscc instead of compil32. I also tried compil64, as my computer is 64 bit, with the same result.
Thanks in advance.
This is basic operating system functionality. You need to either put the directories where the Inno Setup binaries are located into your system PATH, or use a fully qualified pathname to the executables when running them.

Command Prompt on Windows 8 not recognizing any commands

Here's a screenshot of the command prompt message:
It says "'$' is not recognized as an internal or external command, operable program or batch file."
I looked up how to fix it, then changed the PATH in computer properties and updated my Java like they said, but it's still not fixed.
Is gem the name of a program you're trying to run? Because you can just type gem install jekyll without the $. The gem executable would have to be in a folder that's present in the PATH variable.