Hi,
On Mon, Jun 4, 2012 at 12:44 AM, srean srean.l...@gmail.com wrote:
Hi Wolfgang,
I think you are looking for reduceat( ), in particular add.reduceat()
Indeed OP could utilize add.reduceat(...), like:
# tst.py
import numpy as np
def reduce(data, lengths):
ind, ends=
On Fri, Jun 1, 2012 at 6:56 PM, Chris Withers ch...@simplistix.co.uk wrote:
On 01/06/2012 16:39, Benjamin Root wrote:
import numpy
numpy.zeros(10)[-123]
Traceback (most recent call last):
File stdin, line 1, in module
IndexError: index out of bounds
On 4. juni 2012, at 16:27, Thouis (Ray) Jones wrote:
On Fri, Jun 1, 2012 at 6:56 PM, Chris Withers ch...@simplistix.co.uk wrote:
On 01/06/2012 16:39, Benjamin Root wrote:
import numpy
numpy.zeros(10)[-123]
Traceback (most recent call last):
File stdin, line
On Sun, Jun 3, 2012 at 10:06 PM, Charles R Harris charlesr.har...@gmail.com
wrote:
Hi All,
The issue tracking discussion seems to have died. Since github issues
looks to be a viable alternative at this point, I propose to turn it on for
the numpy repository and start directing people in
On Mon, Jun 4, 2012 at 9:34 AM, Ralf Gommers ralf.gomm...@googlemail.comwrote:
On Sun, Jun 3, 2012 at 10:06 PM, Charles R Harris
charlesr.har...@gmail.com wrote:
Hi All,
The issue tracking discussion seems to have died. Since github issues
looks to be a viable alternative at this point,
On Mon, Jun 4, 2012 at 5:21 PM, bob tnur bobtnu...@gmail.com wrote:
Hello every body. I am new to python.
How to remove any row or column of a numpy matrix whose sum is 3.
To obtain and save new matrix P with (sum(anyrow)!=3 and sum(anycolumn)!=3
elements.
I tried like this:
P =
On Mon, Jun 4, 2012 at 9:21 AM, bob tnur bobtnu...@gmail.com wrote:
Hello every body. I am new to python.
How to remove any row or column of a numpy matrix whose sum is 3.
To obtain and save new matrix P with (sum(anyrow)!=3 and sum(anycolumn)!=3
elements.
well, one question is -- do you want
Hi!
I have a one-dimensional ndarray with two fields. I'd like to sort in
descending order by field 'a', breaking ties by sorting in ascending
order by field 'b'.
I've found combinations of sorting and reversing followed by stable
sorting that work, but there must be a straightforward way to do
There is an interesting project called http://huboard.com/The projects
suggests using a few Column Labels that provides a nice card-based window onto
the Github issues.
I have turned on issue tracking and started a few labels. Feel free to add
more / adjust the names as appropriate.
Here's how I sorted primarily by field 'a' descending and secondarily by
field 'b' ascending:
(Note that 'a' is the second column, 'b' is the first)
data
array([('b', 0.03),
('c', 0.03),
('f', 0.03),
('e', 0.01),
('d', 0.04),
('a', 0.04)],
dtype=[('b',
On Mon, May 28, 2012 at 3:15 AM, Mike Hansen mhan...@gmail.com wrote:
In trying to upgrade NumPy within Sage, we notices some differences in
behavior between 1.5 and 1.6. In particular, in 1.5, we have
sage: f = 0.5
sage: f.__array_interface__
{'typestr': '=f8'}
sage: numpy.array(f)
There are two types of swig problems that I was hoping to get some help with.
First, suppose I have some C function
void f(double *x, int nx, double *y, int ny);
where we input one array, and we output another array, both of which should be
the same size.
I have used in my .i file:
On Mon, Jun 4, 2012 at 4:27 PM, Thouis (Ray) Jones tho...@gmail.com wrote:
On Fri, Jun 1, 2012 at 6:56 PM, Chris Withers ch...@simplistix.co.uk wrote:
On 01/06/2012 16:39, Benjamin Root wrote:
import numpy
numpy.zeros(10)[-123]
Traceback (most recent call last):
On Mon, Jun 4, 2012 at 10:00 PM, Thouis (Ray) Jones tho...@gmail.com wrote:
On Mon, Jun 4, 2012 at 4:27 PM, Thouis (Ray) Jones tho...@gmail.com wrote:
I could look into this. There are only ~10 places the code generates
this error, so it should be a pretty minor change.
My initial estimate
On Mon, Jun 4, 2012 at 11:10 AM, Patrick Redmond plredm...@gmail.com wrote:
Here's how I sorted primarily by field 'a' descending and secondarily by
field 'b' ascending:
could you multiply the numeric field by -1, sort, then put it back --
somethign like:
data *- -1
data_sorted = np.sort(data,
Gideon,
For these use cases, you will need to write short wrapper functions yourself.
In the online docs,
http://docs.scipy.org/doc/numpy/reference/swig.interface-file.html
in the section entitled Beyond the Provided Typemaps, subsection A Common
Example, there is an example of how to do
On Monday, June 4, 2012, Chris Barker wrote:
On Mon, Jun 4, 2012 at 11:10 AM, Patrick Redmond
plredm...@gmail.comjavascript:;
wrote:
Here's how I sorted primarily by field 'a' descending and secondarily by
field 'b' ascending:
could you multiply the numeric field by -1, sort, then put
Can you raise an issue on the Github issue tracker for NumPy? These issues
will be looked at more closely. This kind of change should not have made it
in to the release.
off-topic
Given the lack of availability of time from enough experts in NumPy, this is
the sort of thing that can
Using the 'h2' is redundant, but it should not have been changed so quickly.
I could see raising a deprecation warning and communicating the correct
spelling ('i2').
-Travis
On Jun 3, 2012, at 6:45 PM, Benjamin Root wrote:
On Sunday, June 3, 2012, Ralf Gommers wrote:
On Sun,
On Mon, Jun 4, 2012 at 9:30 PM, Travis Oliphant tra...@continuum.io wrote:
Can you raise an issue on the Github issue tracker for NumPy? These issues
will be looked at more closely. This kind of change should not have made it
in to the release.
Thanks Travis! I've made this
20 matches
Mail list logo