Orange Forum • View topic - "No module named orange" 32bit windows

"No module named orange" 32bit windows

A place to ask questions about methods in Orange and how they are used and other general support.

"No module named orange" 32bit windows

Postby rokily » Thu Mar 01, 2012 8:09

Hi all,

I have download and installed the windows Full package: Snapshot of Orange with Python 2.7 and required libraries. The problem is :

>>> import orange
Traceback (most recent call last):
File "<interactive input>", line 1, in <module>
ImportError: No module named orange

but, it's Ok when I uppercase initial letter "import Orange" firstly:

>>> import Orange
D:\Program\Python27\lib\site-packages\Orange\network\__init__.py:59: UserWarning: Warning: some features are disabled. Install networkx to use the 'Orange.network' module.
warnings.warn("Warning: some features are disabled. Install networkx to use the 'Orange.network' module.")
>>> import orange
>>> orange.version
'2.0b (19:12:26, Feb 14 2012)'
>>>

I've tried the Pure Orange: Snapshot of Orange for Python 2.7, there's the same problem.

I missed something or need to config anything?
Can someone give me a hand? thanks.

Re: "No module named orange" 32bit windows

Postby Ales » Thu Mar 01, 2012 15:06

The installer should register the proper paths to find the orange module (but it uses windows registry to do that - this could be a problem if you installed orange under a different user account).
Can you run
Code: Select all
import sys
print sys.path
in a fresh python interpreter. Does the sys.path contain an entry ending in 'site-packages\Orange\orng'.
You can set the path manually by creating an file "any-name-will-do.pth" in "C:\Python27\Lib\site-packages\" and write Orange\orng in it.

Re: "No module named orange" 32bit windows

Postby rokily » Fri Mar 02, 2012 3:03

Ales wrote:The installer should register the proper paths to find the orange module (but it uses windows registry to do that - this could be a problem if you installed orange under a different user account).
Can you run
Code: Select all
import sys
print sys.path
in a fresh python interpreter. Does the sys.path contain an entry ending in 'site-packages\Orange\orng'.
You can set the path manually by creating an file "any-name-will-do.pth" in "C:\Python27\Lib\site-packages\" and write Orange\orng in it.



It works, thank you very much.


Return to Questions & Support