Hello,
if i multiply two matrix, one with a unique line and the second one with a
unique column, i should have a scalar:
line
matrix([[1, 3, 1]])
col
matrix([[2],
[2],
[2]])
line*col
matrix([[10]])
Matlab give me a scalar, Numpy does not...
Do you know why?
Regards,
A Wednesday 03 February 2010 08:42:57 David Cournapeau escrigué:
Yes, it means distributors of packages that depend on NumPy will have
to recompile against the new version, and I can see why some might
want to avoid that. Pushing what is really a distribution problem
back to the NumPy
From an extension? How to import numpy from there and then test if that
succeeded and that without any annoying message if possible...
Thanks,
Peter
On Wed, Feb 3, 2010 at 1:34 AM, David Cournapeau da...@silveregg.co.jpwrote:
Peter Notebaert wrote:
How can I test if numpy is installed on
On Wed, Feb 3, 2010 at 5:38 PM, Peter Notebaert p...@telenet.be wrote:
From an extension? How to import numpy from there and then test if that
succeeded and that without any annoying message if possible...
One obvious solution would be to simply call PyImport_Import, something like:
#include
Hello,
the following operation seems strange to me
np.left_shift(2,-1)
0
I would have expected a right_shift by one.
The documentation on
http://docs.scipy.org/doc/numpy/reference/generated/numpy.left_shift.html#numpy.left_shift
also says that the operation is equivalent to multiplying x1 by
On Wed, Feb 3, 2010 at 8:43 PM, markus.proel...@ifm.com wrote:
Hello,
the following operation seems strange to me
np.left_shift(2,-1)
0
I would have expected a right_shift by one.
I wouldn't expect anything, the behavior is simply not defined. Python
returns an error:
In [17]: 2 -1
On Wed, Feb 3, 2010 at 8:43 PM, markus.proel...@ifm.com wrote:
Hello,
the following operation seems strange to me
np.left_shift(2,-1)
0
I would have expected a right_shift by one.
I wouldn't expect anything, the behavior is simply not defined.
But it would prevent a
On 2/3/2010 3:08 AM, laurent.fe...@free.fr wrote:
if i multiply two matrix, one with a unique line and the second one
with a unique column, i should have a scalar
What definition of matrix multiplication is that??
If you really want a scalar product,
ask for it::
import numpy as np
On Wed, Feb 3, 2010 at 03:41, David Cournapeau courn...@gmail.com wrote:
On Wed, Feb 3, 2010 at 5:38 PM, Peter Notebaert p...@telenet.be wrote:
From an extension? How to import numpy from there and then test if that
succeeded and that without any annoying message if possible...
One obvious
Ah, that is maybe the idea:
if (_import_array() 0) {
/* Clear the error state since we are handling the error. */
PyErr_Clear();
/* ... set up for the sans-numpy case. */
}
else {
/* ... set up for the with-numpy case. */
}
I did not call PyErr_Clear() when _import_array() 0 and
On Wed, Feb 3, 2010 at 5:43 AM, markus.proel...@ifm.com wrote:
Hello,
the following operation seems strange to me
np.left_shift(2,-1)
0
I would have expected a right_shift by one.
The result of a shift by a negative number is undefined in the C language;
the gcc compiler will issue a
David Cournapeau wrote:
Just so that there is no confusion: it is only about removing it for
1.4.x, not about removing datetime altogether. It seems that datetime in
1.4.x has few users,
Of course it has few users -- it's brand new!
whereas breaking ABI is a nuisance for many more
On Wed, Feb 3, 2010 at 12:16 PM, Christopher Barker
chris.bar...@noaa.gov wrote:
David Cournapeau wrote:
Just so that there is no confusion: it is only about removing it for
1.4.x, not about removing datetime altogether. It seems that datetime in
1.4.x has few users,
Of course it has few
On Tue, Feb 2, 2010 at 23:45, Travis Oliphant oliph...@enthought.com wrote:
I consider ABI a very significant think. We should be very accurate
about when a re-compile is required. I just don't believe that we
should be promising ABI compatibility at .X releases. I never had
that
I am pleased to announce the first release of the la package, version 0.1.
The main class of the la package is a labeled array, larry. A larry consists
of a data array and a label list. The data array is stored as a NumPy array
and the label list as a list of lists.
larry has built-in methods
Just to imform that my approach works:
if (_import_array() 0) {
/* Clear the error state since we are handling the error. */
PyErr_Clear();
/* ... set up for the sans-numpy case. */
}
else {
/* ... set up for the with-numpy case. */
}
It is based on Roberts idea to call
Thanks all for your replies...
yes i start with numpy.
i translate a dtw algorithm for voice recogniton from matlab to python
Rgds,
Laurent
- Mail Original -
De: Alan G Isaac ais...@american.edu
À: Discussion of Numerical Python numpy-discussion@scipy.org
Envoyé: Mercredi 3 Février 2010
On Thu, Feb 4, 2010 at 2:16 AM, Christopher Barker
chris.bar...@noaa.gov wrote:
David Cournapeau wrote:
Just so that there is no confusion: it is only about removing it for
1.4.x, not about removing datetime altogether. It seems that datetime in
1.4.x has few users,
Of course it has few
A more important scenario is as follows: let's assume we do allow
breaking the ABI every 1.X release, meaning that an ABI incompatible
change happens every ~ 6 months at the current pace (using the last
2-3
years as history).
If the issue is having too many releases that are .X
On Feb 2, 2010, at 11:59 PM, David Cournapeau wrote:
Travis Oliphant wrote:
On Feb 2, 2010, at 11:46 PM, David Cournapeau wrote:
On Wed, Feb 3, 2010 at 12:23 PM, David Cournapeau
da...@silveregg.co.jp mailto:da...@silveregg.co.jp wrote:
Sorry, my question was badly worded: besides the
On Wed, Feb 3, 2010 at 11:46 PM, Travis Oliphant oliph...@enthought.comwrote:
A more important scenario is as follows: let's assume we do allow
breaking the ABI every 1.X release, meaning that an ABI incompatible
change happens every ~ 6 months at the current pace (using the last 2-3
On Wed, Feb 3, 2010 at 11:48 PM, Travis Oliphant oliph...@enthought.comwrote:
On Feb 2, 2010, at 11:59 PM, David Cournapeau wrote:
Travis Oliphant wrote:
On Feb 2, 2010, at 11:46 PM, David Cournapeau wrote:
On Wed, Feb 3, 2010 at 12:23 PM, David Cournapeau
da...@silveregg.co.jp
On Feb 3, 2010, at 11:58 AM, Robert Kern wrote:
On Tue, Feb 2, 2010 at 23:45, Travis Oliphant
oliph...@enthought.com wrote:
I consider ABI a very significant think. We should be very accurate
about when a re-compile is required.I just don't believe that we
should be promising ABI
On Thu, Feb 4, 2010 at 12:11 AM, Travis Oliphant oliph...@enthought.comwrote:
On Feb 3, 2010, at 11:58 AM, Robert Kern wrote:
On Tue, Feb 2, 2010 at 23:45, Travis Oliphant
oliph...@enthought.com wrote:
I consider ABI a very significant think. We should be very accurate
about when a
On Feb 4, 2010, at 12:59 AM, Charles R Harris wrote:
On Wed, Feb 3, 2010 at 11:48 PM, Travis Oliphant oliph...@enthought.com
wrote:
On Feb 2, 2010, at 11:59 PM, David Cournapeau wrote:
Travis Oliphant wrote:
On Feb 2, 2010, at 11:46 PM, David Cournapeau wrote:
On Wed, Feb 3, 2010
On Thu, Feb 4, 2010 at 12:37 AM, Travis Oliphant oliph...@enthought.comwrote:
On Feb 4, 2010, at 12:59 AM, Charles R Harris wrote:
On Wed, Feb 3, 2010 at 11:48 PM, Travis Oliphant
oliph...@enthought.comwrote:
On Feb 2, 2010, at 11:59 PM, David Cournapeau wrote:
Travis Oliphant wrote:
26 matches
Mail list logo