Francesc Alted wrote:
...
Yeah, I think taking slices here is taking quite a lot of time:
In [58]: timeit E + Xi2[P/2,:]
10 loops, best of 3: 3.95 µs per loop
In [59]: timeit E + Xi2[P/2]
10 loops, best of 3: 2.17 µs per loop
don't know why the additional ',:' in the slice is
Hi,
Suppose I have a flat array, and I want to know the
indices corresponding to values contained in a list
of arbitrary lenght.
Intuitively I would have done:
a = np.array([1,2,3,4])
np.nonzero(a in (0,2,4))
However the in operator doesn't work element-wise,
instead it compares the whole
np.setmember1d(a,b)
does the same as your
reduce(np.logical_or, [a == i for i in b])
but it's actually slower on my machine!
Gary R.
Ernest Adrogué wrote:
Hi,
Suppose I have a flat array, and I want to know the
indices corresponding to values contained in a list
of arbitrary lenght.
On Sat, Dec 12, 2009 at 5:59 AM, Jasper van de Gronde
th.v.d.gro...@hccnet.nl wrote:
Francesc Alted wrote:
...
Yeah, I think taking slices here is taking quite a lot of time:
In [58]: timeit E + Xi2[P/2,:]
10 loops, best of 3: 3.95 µs per loop
In [59]: timeit E + Xi2[P/2]
10
2009/12/12 Ernest Adrogué eadro...@gmx.net:
Hi,
Suppose I have a flat array, and I want to know the
indices corresponding to values contained in a list
of arbitrary lenght.
Intuitively I would have done:
a = np.array([1,2,3,4])
np.nonzero(a in (0,2,4))
However the in operator doesn't
Hi,
Suppose I have an array of shape: (n, k, k). In this case, I have n
k-by-k matrices. My goal is to compute the product of a (potentially
large) user-specified selection (with replacement) of these matrices.
For example,
x = [0,1,2,1,3,3,2,1,3,2,1,5,3,2,3,5,2,5,3,2,1,3,5,6]
says that I
On Sat, Dec 12, 2009 at 4:55 PM, T J tjhn...@gmail.com wrote:
Hi,
Suppose I have an array of shape: (n, k, k). In this case, I have n
k-by-k matrices. My goal is to compute the product of a (potentially
large) user-specified selection (with replacement) of these matrices.
For example,
Le samedi 12 décembre 2009 à 01:55 -0800, T J a écrit :
Is there a better way?
You may have a look at http://scipy.org/Cookbook/MultiDot
Several alternatives are proposed.
Cheers,
--
Denis
___
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
2009/12/12 T J tjhn...@gmail.com:
Hi,
Suppose I have an array of shape: (n, k, k). In this case, I have n
k-by-k matrices. My goal is to compute the product of a (potentially
large) user-specified selection (with replacement) of these matrices.
For example,
x =
Here is a log form a build of svn rev 7996 with no LDFLAGS specified, as
recommended by Robert. The result is the same, however.
http://files.me.com/fonnesbeck/y7e9v2
cf
___
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
On Sat, Dec 12, 2009 at 8:08 PM, THOMAS BROWNE totalb...@mac.com wrote:
Hello all,
Quite new to numpy / timeseries module, please forgive the elementary
question.
I wish to do quite to do a bunch of multivariate analysis on 1000 different
financial markets series, each holding about 1800
Have you considered creating a TimeSeries for each data series, and
then putting them all together in a dict, keyed by symbol?
One disadvantage of one big monster numpy array for all the series is
that not all series may have a full set of 1800 data points. So the
array isn't really nicely
On Sun, Dec 13, 2009 at 4:27 AM, Chris fonnesb...@gmail.com wrote:
Here is a log form a build of svn rev 7996 with no LDFLAGS specified, as
recommended by Robert. The result is the same, however.
http://files.me.com/fonnesbeck/y7e9v2
I don't see any build error on this log ?
David
On Sun, Dec 13, 2009 at 00:37, David Cournapeau courn...@gmail.com wrote:
On Sun, Dec 13, 2009 at 4:27 AM, Chris fonnesb...@gmail.com wrote:
Here is a log form a build of svn rev 7996 with no LDFLAGS specified, as
recommended by Robert. The result is the same, however.
So far, no one has voiced objections, so should I go ahead and check
this in?
btw, thanks Mike, what about this one:
(np.char.lstrip(c, ' ') == np.char.lstrip(c, '')).all()
... # XXX: is this a regression? this line now returns False -pi
... # np.char.lstrip(c,'') does not modify c
15 matches
Mail list logo