thinning algorithms in GRASS

Simon Cox S.Cox at solo.ned.dem.csiro.au
Wed Sep 20 08:00:00 EDT 1995


>the original cost construction, etc.?  Does anyone know how precise the
>thinning algorithms are and how do you translate any error into a number
>(is it additive with the RMS of the underlying surface???)

Gillian

I presume that you use r.thin followed by r.line.

I don't understand the statistical questions that you are asking,
but I can offer the following.  It sounds like you might be coming
across a variant of the old "Manhattan" distance problem, in which
the shortest distance between equally spaced points on a _grid_
depends on the azimuth between them.

Here, it works like this:  The thinning step (r.thin) simply
eats away at lines until they are only one cell wide.  What happens
at intersections is a bit more complex, but on "reaches" it works
well.  This "one cell" is, of course, the limiting resolution
imposed by the input map (and current region settings if they
are different).

R.line then simply searches along contiguous strings of cells,
and creates a vector map by joining together the cell centres along
the line.  For any line which is not either aligned with the input grid
or at 45o to it, this means that it comes out quite "jagged".  You
can verify this by looking at the vector map at high magnification:
you will find that all the lines are built up from segments at
0, 45, 90, 135.  This may seem wierd , _but_ given the input cell map
it is the only "honest" way of doing it.

I think it would be fair to say that the r.thin+r.line method of
vectorization works well for converting "areas", but in order to get
good metrics from "lines" or "polygon _boundaries_" you need to look
at some kind of "smoothing" of the line map to regularize it.  The
latter could be quite a programming task.  Any takers?

Simon Cox

___________________________________________________________
Dr Simon Cox                          __  \
CSIRO Exploration & Mining         ,~'  L_|\    Australian
39 Fairway, PO Box 437,         ;-'         \   Geodynamics
Nedlands, WA  6009  Australia   (            \  Cooperative
      Phone +61 9 284 8443      +    ___     /  Research
      Fax   +61 9 389 1906       L~~'   "\__/   Centre
simon at ned.dem.csiro.au                     W
AGCRC info>>   http://www.ned.dem.csiro.au/AGCRC/
___________________________________________________________







More information about the grass-user mailing list