enthought

Python file open() in Enthought Canopy fails with: “IOError No such file or directory”

霸气de小男生 提交于 2019-11-29 04:25:24
I'm running code under Enthought Canopy to open and read a file. It keeps telling me IOError. But I am pretty sure the text file name is right and it is in the same directory with the Python file, and the code works well in other IDEs like Python IDLE. Don't know what's wrong. Any suggestions? inFile = open('words.txt', 'r') words = inFile.read().split() fails with IOError: [Errno 2] No such file or directory: 'words.txt' punchagan UPDATE: The following hack is not required in Canopy versions 1.0.3 and greater. Right click inside the Python pane, and select Keep Directory Synced to Editor .

PyAudio IOError: No Default Input Device Available

帅比萌擦擦* 提交于 2019-11-29 02:56:58
I'm using PyAudio under the Enthought Python Distribution (Python 2.6.6) in Ubuntu 10.10 x64. >>> import pyaudio >>> pa = pyaudio.PyAudio() >>> pa.get_default_input_device_info() Traceback (most recent call last): File "<pyshell#24>", line 1, in <module> pa.get_default_input_device_info() File "/usr/lib/python_epd/lib/python2.6/site-packages/pyaudio.py", line 936, in get_default_input_device_info device_index = pa.get_default_input_device() IOError: No Default Input Device Available This is the same error I get if I try to open an input stream. There is the corresponding error "IOError: No

ImportError: No module named Cython.Distutils

安稳与你 提交于 2019-11-28 18:07:00
I'm having a strange problem while trying to install the Python library zenlib , using its setup.py file. When I run the setup.py file, I get an import error, saying ImportError: No module named Cython.Distutils` but I do have such a module, and I can import it on the python command line without any trouble. Why might I be getting this import error? I think that the problem may have to do with the fact that I am using Enthought Python Distribution , which I installed right beforehand, rather than using the Python 2.7 that came with Ubuntu 12.04. More background: Here's exactly what I get when

Installing Theano on EPD (Windows x64)

我的未来我决定 提交于 2019-11-28 09:41:38
问题 I'm trying to install Theano on Enthought Python Distribution (EPD), but I am getting a weird error. Here is what my installation looks like: I have installed EPD to C:\Python27 . After that, I have installed pip by using easy_install pip I installed Theano by using pip install Theano To test, I start ipython and type import theano . I get the following error: Problem occurred during compilation with the command line below: g++ -shared -g -IC:\Python27\lib\site-packages\numpy\core\include -IC

Enthought Canopy doesn't print right away when statement occurs

纵然是瞬间 提交于 2019-11-28 05:14:51
问题 A while ago I switched from Enthought's old EPD to their newer Canopy system. For the most part it's nice, but one aspect has been particularly vexing. Whenever I run a python script, either from within the Canopy iPython environment or from the command line, none of my print statements actually get printed right away when that part of the script is hit. Instead, multiple print s seem to get executed all at once at a later time. As an example... import numpy as np print "About to start long

Distutils compiler options configuration

女生的网名这么多〃 提交于 2019-11-28 03:35:53
问题 Maybe a stupid question, but I was wondering where Python's distutils get the compiler options from? It gets some linked directories wrong and I want to correct that once and for all. I know there should be a prefix/lib/pythonver/distutils/distutils.cfg but I can't find any distutils.cfg anywhere on the computer. Obviously I haven't got a local setup.cfg or any $HOME/.pydistutils.cfg. I'm using the Enthought 64-bit distribution, version 7.3 (Python 2.7) on Mac OS X 10.8.3 Cheers, U. 回答1: I

PyAudio IOError: No Default Input Device Available

[亡魂溺海] 提交于 2019-11-27 22:02:27
问题 I'm using PyAudio under the Enthought Python Distribution (Python 2.6.6) in Ubuntu 10.10 x64. >>> import pyaudio >>> pa = pyaudio.PyAudio() >>> pa.get_default_input_device_info() Traceback (most recent call last): File "<pyshell#24>", line 1, in <module> pa.get_default_input_device_info() File "/usr/lib/python_epd/lib/python2.6/site-packages/pyaudio.py", line 936, in get_default_input_device_info device_index = pa.get_default_input_device() IOError: No Default Input Device Available This is

Python 3 in Enthought Canopy

对着背影说爱祢 提交于 2019-11-27 21:30:22
How to use Python 3 in Canopy Enthought? It has the option on the bottom to select Python 3, but this does not change anything when we use: print(sys.version) 2.7.3 | 32-bit | (default, Mar 25 2013, 15:38:39) [MSC v.1500 32 bit (Intel)] An Enthought engineer answered that at present it is not possible to use Python 3 in or with Canopy . They are considering several ways to support it but none of them will arrive in the short term. Edit : Enthought just announced Python 3 support for Canopy 2.0 . as you can see on https://www.enthought.com/products/canopy/package-index/ most(or some) packages

Python file open() in Enthought Canopy fails with: “IOError No such file or directory”

|▌冷眼眸甩不掉的悲伤 提交于 2019-11-27 18:26:23
问题 I'm running code under Enthought Canopy to open and read a file. It keeps telling me IOError. But I am pretty sure the text file name is right and it is in the same directory with the Python file, and the code works well in other IDEs like Python IDLE. Don't know what's wrong. Any suggestions? inFile = open('words.txt', 'r') words = inFile.read().split() fails with IOError: [Errno 2] No such file or directory: 'words.txt' 回答1: UPDATE: The following hack is not required in Canopy versions 1.0