#839: INSPIRE: numpy broken on -dev, -test
-----------------------+-----------------
Reporter: jblayloc | Owner:
Type: defect | Status: new
Priority: major | Milestone:
Component: *general* | Version:
Keywords: INSPIRE |
-----------------------+-----------------
The following behavior shows that *something* (I haven't investigated
what) is messed with the numpy installation on -dev and -test:
{{{
jblayloc@pcudssw1505:~$ ipython
Python 2.4.3 (#1, May 6 2011, 09:25:14)
Type "copyright", "credits" or "license" for more information.
IPython 0.8.4 -- An enhanced Interactive Python.
? -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help -> Python's own help system.
object? -> Details about 'object'. ?object also works, ?? prints more.
In [1]: from numpy import *
In [2]: histogram(array([0, 1, 2, 2, 1, 3]), [0, 2, 3])
---------------------------------------------------------------------------
NameError Traceback (most recent call
last)
/afs/cern.ch/user/j/jblayloc/<ipython console>
/usr/lib64/python2.4/site-packages/numpy/lib/function_base.pyc in
histogram(a, bins, range, normed)
152 bins = linspace(mn, mx, bins, endpoint=False)
153 else:
--> 154 if(any(bins[1:]-bins[:-1] < 0)):
155 raise AttributeError, 'bins must increase
monotonically.'
156
NameError: global name 'any' is not defined
}}}
While the production servers don't display this problem, it's still quite
annoying because I'd like to be able to interact with the document sets on
-dev and -test with ipython and reliably do useful things. Its
particularly perplexing because:
{{{
jblayloc@pcudssw1505:~$ ipython
Python 2.4.3 (#1, May 6 2011, 09:25:14)
Type "copyright", "credits" or "license" for more information.
IPython 0.8.4 -- An enhanced Interactive Python.
? -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help -> Python's own help system.
object? -> Details about 'object'. ?object also works, ?? prints more.
In [1]: from numpy import *
In [2]: any(True, False, False, False)
---------------------------------------------------------------------------
TypeError Traceback (most recent call
last)
/afs/cern.ch/user/j/jblayloc/<ipython console>
TypeError: any() takes at most 3 arguments (4 given)
In [3]: any([True, False, False, False])
Out[3]: True
}}}
any does actually appear to work fine.
Could it be some python library pathing problem?
--
Ticket URL: <http://invenio-software.org/ticket/839>
Invenio <http://invenio-software.org>