Re: Following a ridgeline [message #60862] |
Wed, 18 June 2008 11:10  |
Jelle
Messages: 19 Registered: May 2008
|
Junior Member |
|
|
On Jun 18, 4:55 pm, Jean H <jghas...@DELTHIS.ucalgary.ANDTHIS.ca>
wrote:
> I like the "why programmers are lazy and dumb" link on your page.. it is
> indeed hard to solve a problem that can not be defined :-)
>
> Jean
hehe, me too. For those who might like it but are not keen to see my
personal site; it points to this site: http://blogoscoped.com/archive/2005-08-24-n14.html
|
|
|
|
|
|
|
|
Re: Following a ridgeline [message #60890 is a reply to message #60884] |
Tue, 17 June 2008 02:20   |
RJA
Messages: 2 Registered: May 2006
|
Junior Member |
|
|
On 16 Jun, 20:24, "mzagu...@gmail.com" <mzagu...@gmail.com> wrote:
> Hi,
>
> I've got a 2d map (let's say it's a contour map of a mountain). I
> need to be able to 'detect' and 'follow' the ridgeline across the
> whole mountain (which does about a 180 degree turn as well, it's U
> shaped). Anyone know any way to accomplish this?
>
> So far, i've attempted to start at the maximum point, and then look
> for surrounding points that minimizes the downward slope, this
> process, however, creates switchbacks at peaks and doesnt follow the
> peak down along a ridge. Any ideas?
>
> Thanks!
Have you tried to find the medial axis? The thin() function calculates
this for you.
Cheers, Richard.
|
|
|
|
|
|
Re: Following a ridgeline [message #60894 is a reply to message #60893] |
Mon, 16 June 2008 13:34   |
mzagursk@gmail.com
Messages: 9 Registered: June 2008
|
Junior Member |
|
|
On Jun 16, 1:15 pm, "mzagu...@gmail.com" <mzagu...@gmail.com> wrote:
> On Jun 16, 12:49 pm, David Fanning <n...@dfanning.com> wrote:
>
>
>
>> mzagu...@gmail.com writes:
>>> I've got a 2d map (let's say it's a contour map of a mountain). I
>>> need to be able to 'detect' and 'follow' the ridgeline across the
>>> whole mountain (which does about a 180 degree turn as well, it's U
>>> shaped). Anyone know any way to accomplish this?
>
>>> So far, i've attempted to start at the maximum point, and then look
>>> for surrounding points that minimizes the downward slope, this
>>> process, however, creates switchbacks at peaks and doesnt follow the
>>> peak down along a ridge. Any ideas?
>
>> The obvious idea is the WATERSHED function. Have you
>> tried that?
>
>> Cheers,
>
>> David
>> --
>> David Fanning, Ph.D.
>> Fanning Software Consulting, Inc.
>> Coyote's Guide to IDL Programming:http://www.dfanning.com/
>> Sepore ma de ni thui. ("Perhaps thou speakest truth.")
>
> Yes, but I'm not sure how to implement it in such a way to output the
> ridge. This 'image' is simply a background of 0's with a single
> ridgeline rising out of it. When I use watershed, it give me bogus
> answers, lines that make no sense at all.
Here's an image of what I'm talking about: http://www.mattzag.com/mountain_example.tiff
I need to follow the long ridgeline and output those points. Thanks a
bunch.
|
|
|
Re: Following a ridgeline [message #60895 is a reply to message #60893] |
Mon, 16 June 2008 13:15   |
mzagursk@gmail.com
Messages: 9 Registered: June 2008
|
Junior Member |
|
|
On Jun 16, 12:49 pm, David Fanning <n...@dfanning.com> wrote:
> mzagu...@gmail.com writes:
>> I've got a 2d map (let's say it's a contour map of a mountain). I
>> need to be able to 'detect' and 'follow' the ridgeline across the
>> whole mountain (which does about a 180 degree turn as well, it's U
>> shaped). Anyone know any way to accomplish this?
>
>> So far, i've attempted to start at the maximum point, and then look
>> for surrounding points that minimizes the downward slope, this
>> process, however, creates switchbacks at peaks and doesnt follow the
>> peak down along a ridge. Any ideas?
>
> The obvious idea is the WATERSHED function. Have you
> tried that?
>
> Cheers,
>
> David
> --
> David Fanning, Ph.D.
> Fanning Software Consulting, Inc.
> Coyote's Guide to IDL Programming:http://www.dfanning.com/
> Sepore ma de ni thui. ("Perhaps thou speakest truth.")
Yes, but I'm not sure how to implement it in such a way to output the
ridge. This 'image' is simply a background of 0's with a single
ridgeline rising out of it. When I use watershed, it give me bogus
answers, lines that make no sense at all.
|
|
|
Re: Following a ridgeline [message #60896 is a reply to message #60893] |
Mon, 16 June 2008 12:49   |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
mzagursk@gmail.com writes:
> I've got a 2d map (let's say it's a contour map of a mountain). I
> need to be able to 'detect' and 'follow' the ridgeline across the
> whole mountain (which does about a 180 degree turn as well, it's U
> shaped). Anyone know any way to accomplish this?
>
> So far, i've attempted to start at the maximum point, and then look
> for surrounding points that minimizes the downward slope, this
> process, however, creates switchbacks at peaks and doesnt follow the
> peak down along a ridge. Any ideas?
The obvious idea is the WATERSHED function. Have you
tried that?
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
|
|
|
Re: Following a ridgeline [message #60934 is a reply to message #60884] |
Tue, 24 June 2008 08:53  |
Mike[2]
Messages: 99 Registered: December 2005
|
Member |
|
|
On Jun 17, 1:14 pm, Jean H <jghas...@DELTHIS.ucalgary.ANDTHIS.ca>
wrote:
> What about edge detection filters? ... the Canny edge detector seems
> to be fairly good
The first part of the Canny edge detector is the calculation of a
gradient image. Then it follows gradient contours. With appropriate
choice of the smoothing parameter, it aught to do fairly well.
Mike
|
|
|
Re: Following a ridgeline [message #60969 is a reply to message #60894] |
Mon, 23 June 2008 00:50  |
karo03de
Messages: 21 Registered: March 2007
|
Junior Member |
|
|
Have a look at http://picasaweb.google.de/karo03de/Idl
Left you see a distance transformed binary image a with the result of
thin(a) in red, unluckily not exact and not connected, an error existant
since the beginnings of idl. In fact thin is working on the binary image.
The skeleton should correspond with the ridge lines of the distance
transformed binary image!
tvscl,a,0
tvscl,thin(a),0,chan=1
Right a possible result performed by my program, which is not easily to be
transfered (dll and a bunch of software). mm_skeleton is a "real" grey
scale skeleton, performed by succeeding hit-or-miss transformations.
tvscl,a,1
tvscl,mm_skelton(a),0,chan=1,1
Mathematical morphology is the keyword for this! Watershed delivers just
the contrary of what you are looking for! watershed borders are some sort
of saddle points in the distance map.
Regards
Karsten
Am Mon, 16 Jun 2008 22:34:20 +0200 schrieb mzagursk@gmail.com
<mzagursk@gmail.com>:
> On Jun 16, 1:15 pm, "mzagu...@gmail.com" <mzagu...@gmail.com> wrote:
>> On Jun 16, 12:49 pm, David Fanning <n...@dfanning.com> wrote:
>>
>>
>>
>>> mzagu...@gmail.com writes:
>>>> I've got a 2d map (let's say it's a contour map of a mountain). I
>>>> need to be able to 'detect' and 'follow' the ridgeline across the
>>>> whole mountain (which does about a 180 degree turn as well, it's U
>>>> shaped). Anyone know any way to accomplish this?
>>
>>>> So far, i've attempted to start at the maximum point, and then look
>>>> for surrounding points that minimizes the downward slope, this
>>>> process, however, creates switchbacks at peaks and doesnt follow the
>>>> peak down along a ridge. Any ideas?
>>
>>> The obvious idea is the WATERSHED function. Have you
>>> tried that?
>>
>>> Cheers,
>>
>>> David
>>> --
>>> David Fanning, Ph.D.
>>> Fanning Software Consulting, Inc.
>>> Coyote's Guide to IDL Programming:http://www.dfanning.com/
>>> Sepore ma de ni thui. ("Perhaps thou speakest truth.")
>>
>> Yes, but I'm not sure how to implement it in such a way to output the
>> ridge. This 'image' is simply a background of 0's with a single
>> ridgeline rising out of it. When I use watershed, it give me bogus
>> answers, lines that make no sense at all.
>
> Here's an image of what I'm talking about:
> http://www.mattzag.com/mountain_example.tiff
> I need to follow the long ridgeline and output those points. Thanks a
> bunch.
--
Erstellt mit Operas revolutionᅵrem E-Mail-Modul: http://www.opera.com/m2/
|
|
|