Public bug reported:
Binary package hint: python-numpy
Hi there!
If you have and array with complex values, and try to execute:
numpy.amax(array), amax, brings a result the max number of the array, but it
only search in the real part.
I think that there shouldn't be result, like it happens when you call the max
methods on a simple list.
In [1]: import numpy as np
In [2]: a_list = [1+2j, 1+3j, 2+2j,1+100j, 5+1j]
In [3]: a_np = np.array([1+2j, 1+3j, 2+2j,1+100j, 5+1j])
In [4]: np.amax(a_np)
Out[4]: (5+1j)
In [5]: max(a_list)
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
/home/malev/<ipython console> in <module>()
TypeError: no ordering relation is defined for complex numbers
finally, I'm using:
Python 2.6.4 (r264:75706, Dec 7 2009, 18:45:15)
and numpy: '1.3.0'
I've tried to submit the ticket at the numpy list, but it said I didn't have
the privileges. That is why I'm coming here.
Regards
malev
ProblemType: Bug
Architecture: i386
Date: Tue Feb 23 16:42:20 2010
DistroRelease: Ubuntu 9.10
ExecutablePath: /usr/bin/yelp
InstallationMedia: Ubuntu 9.10 "Karmic Koala" - Release i386 (20091028.5)
NonfreeKernelModules: wl
Package: yelp 2.28.0-0ubuntu2
ProcEnviron:
LANG=es_AR.UTF-8
SHELL=/bin/bash
ProcVersionSignature: Ubuntu 2.6.31-19.56-generic
SourcePackage: yelp
Uname: Linux 2.6.31-19-generic i686
XsessionErrors:
(gnome-settings-daemon:2016): GLib-CRITICAL **: g_propagate_error: assertion
`src != NULL' failed
(gnome-settings-daemon:2016): GLib-CRITICAL **: g_propagate_error: assertion
`src != NULL' failed
(/usr/lib/gnome-do/Do.exe:2212): GLib-WARNING **: g_set_prgname() called
multiple times
(polkit-gnome-authentication-agent-1:2226): GLib-CRITICAL **:
g_once_init_leave: assertion `initialization_value != 0' failed
(firefox:2547): GLib-WARNING **: g_set_prgname() called multiple times
** Affects: python-numpy (Ubuntu)
Importance: Undecided
Status: New
** Tags: apport-bug i386
--
[amax()] bad behaviour with complex arrays
https://bugs.launchpad.net/bugs/526636
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs