Re: [Numpy-discussion] Neighbour-frequency matrix

2009-07-16 Thread Stéfan van der Walt
2009/7/15 David Warde-Farley : > Here's an interesting problem, and it might've already been solved by > some of you folks that do image processing: > > Suppose I have an 8-bit integer 2-d array, X, and I want a 256x256 > matrix that tells me how many times a pixel value v was horizontally > (along

Re: [Numpy-discussion] Neighbour-frequency matrix

2009-07-15 Thread Vebjorn Ljosa
On Jul 15, 2009, at 19:37, David Warde-Farley wrote: > > Just curious - I noticed in the comments that you (or someone) said > there's a problem in the original paper's definition. Do you have any > idea which feature that concerned? The comments in our previous (Matlab) version of CellProfiler [1

Re: [Numpy-discussion] Neighbour-frequency matrix

2009-07-15 Thread David Warde-Farley
On 15-Jul-09, at 6:40 PM, Vebjorn Ljosa wrote: > On Jul 15, 2009, at 17:51, David Warde-Farley wrote: > >> Suppose I have an 8-bit integer 2-d array, X, and I want a 256x256 >> matrix that tells me how many times a pixel value v was horizontally >> (along second dimension) adjacent to a pixel val

Re: [Numpy-discussion] Neighbour-frequency matrix

2009-07-15 Thread Vebjorn Ljosa
On Jul 15, 2009, at 17:51, David Warde-Farley wrote: > Suppose I have an 8-bit integer 2-d array, X, and I want a 256x256 > matrix that tells me how many times a pixel value v was horizontally > (along second dimension) adjacent to a pixel value b > Is there an efficient way to do such a thing wi

[Numpy-discussion] Neighbour-frequency matrix

2009-07-15 Thread David Warde-Farley
Here's an interesting problem, and it might've already been solved by some of you folks that do image processing: Suppose I have an 8-bit integer 2-d array, X, and I want a 256x256 matrix that tells me how many times a pixel value v was horizontally (along second dimension) adjacent to a pix