A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://mail.python.org/pipermail/python-list/2001-April/074756.html below:

numeric: local neighbour hood functions on arrays

numeric: local neighbour hood functions on arrays numeric: local neighbour hood functions on arraysRobert Denham Robert.Denham at dnr.qld.gov.au
Fri Apr 6 02:23:30 EDT 2001
I have a question about applying a local filter to an array.
What would be the most efficient way of creating a new array consisting
of a function of a pixels neighbourhood.

Eg, take a 3x3 neighbourhood, and say the sum of the pixels in the
neighbourhod.

eg   1 1 1
       2 x 1   the x is replaced by 8.  This would be repeated for every
element of the array.
       1 0 1

What to do on the boundaries is less of a numerical problem than a
philosophical one.  I can work that out later.

I am sure this is a frequently used type of function, so I would welcome
any suggestions.

Robert Denham
Department of Natural Resources
Queensland Australia



More information about the Python-list mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4