Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

import errors. #263

Closed
CruzzRazor opened this issue Nov 26, 2017 · 7 comments
Closed

import errors. #263

CruzzRazor opened this issue Nov 26, 2017 · 7 comments

Comments

@CruzzRazor
Copy link

i am getting the following error since last 3 days. not able to get rid of this.

'gcc' is not recognized as an internal or external command,
operable program or batch file.
Traceback (most recent call last):
File "C:/Users/allud/ocropus_venv/Scripts/ocropus-nlbin", line 15, in
import ocrolib
File "c:\python27\Lib\ocrolib_init_.py", line 12, in
import common
File "c:\python27\Lib\ocrolib\common.py", line 34, in
import lstm
File "c:\python27\Lib\ocrolib\lstm.py", line 38, in
import nutils
File "c:\python27\Lib\ocrolib\nutils.py", line 25, in
lstm_native = compile_and_load(lstm_utils)
File "c:\python27\Lib\ocrolib\native.py", line 69, in compile_and_load
path = compile_and_find(c_string,**keys)
File "c:\python27\Lib\ocrolib\native.py", line 65, in compile_and_find
raise CompileError()
ocrolib.native.CompileError
(ocropus_venv)

please help.

@amitdo
Copy link
Contributor

amitdo commented Nov 26, 2017

ocropy currently depends on gcc.

Check that gcc is installed on your system.

To ocropy team:
The native code can be dropped and replaced by np.einsum(), which is very fast.

@amitdo
Copy link
Contributor

amitdo commented Nov 26, 2017

I'm not sure if ocropy was ever tested to work on windows.

@zuphilip
Copy link
Collaborator

a) Ocropy is currently not supported to run on windows directly, also it might work with some hacks. Usually, for windows I would suggest you rather to use this docker container. However, some other people tried to run ocropy on windows already, see #73.

b) @amitdo wrote:

The native code can be dropped and replaced by np.einsum(), which is very fast.

This sounds interesting. Can you create a PR for this?

@amitdo
Copy link
Contributor

amitdo commented Nov 26, 2017

This sounds interesting. Can you create a PR for this?

I will do so :-)

@amitdo
Copy link
Contributor

amitdo commented Nov 26, 2017

Another possible way to run ocropy on Windows 10:
https://en.wikipedia.org/wiki/Windows_Subsystem_for_Linux

I didn't try it (I only have Linux)

@urhub
Copy link

urhub commented Nov 26, 2017

I am running Ocropy on bash for windows 10. It works fine. By default it does not run the GUI and so you cannot see any plots. I am not sure that it can.

@CruzzRazor
Copy link
Author

solved this issue on windows itself.installed mingw gcc of latest version and compatible with python
eg. 64 bit mngwgcc on 64 bit python 2.7.14 on 64 bit windows 10. thanks for support

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants