How to carry out edge detection on DEM?

3687
2
02-20-2017 03:21 AM
BenTurner2
New Contributor

Hi Guys. I have a DEM for the remains of a fort and am wanting to carry out edge detection processes. I'm very unexperienced with this type of analysis and am lost after carrying out high and low pass filters. I ideally would like to carry out some of the convolution processes outlined in the Arc guide however can't figure out where to find these tools. Please help!! 

0 Kudos
2 Replies
DanPatterson_Retired
MVP Emeritus

you are referring to the convolutions filters I assume. And you have used the filter tool first?

0 Kudos
DanPatterson_Retired
MVP Emeritus

Image analyst window processing

functions used

convolution functions

A demo of the process not using the above.  The details are not important yet, but the principles are the same. 

  • Start with a filter... ie the  'gradient east' filter can be used for edge detection in the east direction
  • take an array... in the example below, 4 blocks of numbers with a distinct pattern
  • a moving window operation does some magic by breaking the array into 3x3 windows, multiplying by the filter and summing (see 'filtered').
  •  the filtered array, in this case, is simply converted to a binary/indicator array, where '1' represents the edge

That is basically what the raster functions do.  I have done this in numpy but the principles are the same

:------------------------------------------------------------------
:gradient east ... filter...
[[ 1  0 -1]
 [ 2  0 -2]
 [ 1  0 -1]]
:array...
[[1 1 1 1 1 2 2 2 2 2]
 [1 1 1 1 1 2 2 2 2 2]
 [1 1 1 1 1 2 2 2 2 2]
 [1 1 1 1 1 2 2 2 2 2]
 [1 1 1 1 1 2 2 2 2 2]
 [3 3 3 3 3 4 4 4 4 4]
 [3 3 3 3 3 4 4 4 4 4]
 [3 3 3 3 3 4 4 4 4 4]
 [3 3 3 3 3 4 4 4 4 4]
 [3 3 3 3 3 4 4 4 4 4]]
:filtered...
[[ 0  0  0 -4 -4  0  0  0]
 [ 0  0  0 -4 -4  0  0  0]
 [ 0  0  0 -4 -4  0  0  0]
 [ 0  0  0 -4 -4  0  0  0]
 [ 0  0  0 -4 -4  0  0  0]
 [ 0  0  0 -4 -4  0  0  0]
 [ 0  0  0 -4 -4  0  0  0]
 [ 0  0  0 -4 -4  0  0  0]]
:converted to 0,1
[[0 0 0 0 0 0 0 0 0 0]
 [0 0 0 0 1 1 0 0 0 0]
 [0 0 0 0 1 1 0 0 0 0]
 [0 0 0 0 1 1 0 0 0 0]
 [0 0 0 0 1 1 0 0 0 0]
 [0 0 0 0 1 1 0 0 0 0]
 [0 0 0 0 1 1 0 0 0 0]
 [0 0 0 0 1 1 0 0 0 0]
 [0 0 0 0 1 1 0 0 0 0]
 [0 0 0 0 0 0 0 0 0 0]]‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍
0 Kudos