:51 AM, Warren Weckesser wrote:
On Sat, Dec 3, 2011 at 12:35 AM, Robin Kraft wrote:
I need to take an array - derived from raster GIS data - and upsample or
scale it. That is, I need to repeat each value in each dimension so that,
for example, a 2x2 array becomes a 4x4 array as follows
there, but it seems
doable.
Anyone know what combination of manipulations would work with the result of
np.tile?
-Robin
On Dec 3, 2011, at 11:05 AM, Olivier Delalleau wrote:
You can also use numpy.tile
-=- Olivier
2011/12/3 Robin Kraft
Thanks Warren, this is great, and even handles
],
[1, 1, 2, 2],
[3, 3, 4, 4],
[3, 3, 4, 4]]])
On Dec. 3, 2011, at 12:50PM, Derek Homeier wrote:
On 03.12.2011, at 6:22PM, Robin Kraft wrote:
That does repeat the elements, but doesn't get them into the desired order.
In [4]: print a
[[1 2]
[3 4]]
In [7
I need to take an array - derived from raster GIS data - and upsample or scale
it. That is, I need to repeat each value in each dimension so that, for
example, a 2x2 array becomes a 4x4 array as follows:
[[1, 2],
[3, 4]]
becomes
[[1,1,2,2],
[1,1,2,2],
[3,3,4,4]
[3,3,4,4]]
It seems like
Git is having some kind of major outage:
http://status.github.com/
The site and git access is unavailable due to a database failure. We're
researching the issue.
On Nov 14, 2010, at 3:29 PM, numpy-discussion-requ...@scipy.org wrote:
Message: 5
Date: Sun, 14 Nov 2010 13:29:03 -0700
From:
Vincent, Pauli,
From: Vincent Schut sc...@sarvision.nl
- an other option would be some smart reshaping, which finally gives you
a [y//2, x//2, 2, 2] array, which you could then reduce to calculate
stats (mean, std, etc) on the last two axes. I *think* you'd have to
first reshape both x
Hello all,
The short version: For a given NxN array, is there an efficient way to use a
moving window to collect a summary statistic on a chunk of the array, and
insert it into another array?
The long version: I am trying to resample an image loaded with GDAL into an NxN
array. Note that this