On 09/23/2014 01:35 PM, Patrick Leinenkugel wrote:
Hi Adrian,
I use Python(x,y) Version 2.7.6.1 that includes Spyder 2.5.5 and Python
2.7.6 32bits. I then realized that there was a newer version of Spyder
and updated to Spyder 2.3.1 using the executable offered on the Spyder
website. But this could not be the reason, since the error also appeared
when using the Spyder Version that came together with Python(y,x). I did
not update Python and I only have Python 2.7.6 installed on my computer.
Thus it is definitely the same Python version and numpy module that I
use in IDLE and Spyder.
Alright, trying to get a handle on the moving parts. I tried your code
here on Linux using Spyder 2.3.1 and did not get a MemoryError.
What I did see:
1) Using the IPython console I ran your code as is with no issues.
2) In the Python console, when I ran your code as is I found that it did
not actually run. So when I did:
from numpy import *
a_flt = ones((7000,7000), dtype=float64)+4
and then
a_flt <Enter> I got:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
NameError: name 'a_flt' is not defined
If I did
import numpy
a_flt = numpy.ones((7000, 7000),dtype=numpy.float64)+4
then everything worked. I could create multiple *_flt objects with no
problems.
I suspect there is an import conflict going on in the Python console
versus the IPython console. To get a handle on this I would suggest:
1) Try running the code in the IPython console. It should be there, as
PythonXY installs IPython
2) Look in Preferences --> Console --> Advanced Settings and see what
the console is using in the PYTHONSTARTUP replacement section.
Cheers,
Patrick
--
Adrian Klaver
[email protected]
--
You received this message because you are subscribed to the Google Groups
"spyder" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/spyderlib.
For more options, visit https://groups.google.com/d/optout.