Discussion:
[Gwyddion-users] Watershed algorithm - Marked grains are smaller than the size of a single drop?
Jens Trollmann
2014-02-06 14:28:49 UTC
Permalink
Dear users,

I am working with the watershed algorithm to mark grains and I am
wondering what exactly is meant by the parameter drop size in
percentage. I interpreted this in that way that a drop with a size of
0.1% has a size of 0.001µm² in a 1µm² picture. Is that right?

If so, in a 1µm² picture with 512x512 pixels this drop would have a size
of approximately 272 px², so that the smallest lake/grain marked in the
end should be bigger or equal to 272px², shouldn't it? But I get a lot
of marked grains smaller than this size in my picture (e.g. I can erase
a lot of drops via a surface threshold of lets say 60px²). Which mistake
did I make in my thoughts?

Or is percentage of a volume meant and if so what scale is taken as the
"height" of the volume?

One more question apart from that came into my mind:
Can a drop go into a minimum that is smaller than the size of the drop?
I.e. is the drop "really" a fluid and can change its shape?

Unfortunately I did not find information about this on the Gwyddion web
pages. I would be very thankful for any help.

Best regards,
Jens Trollmann
--
----------------------------------------------------------------------------
Jens Trollmann

Kirchhoff-Institut fuer Physik der Universitaet Heidelberg
Im Neuenheimer Feld 227
D-69120 Heidelberg
Raum: 02.301

Tel: +49 6221 54-9892
Fax: +49 6221 54-9875

E-Mail: ***@kip.uni-heidelberg.de
PGP Public Key: http://www.kip.uni-heidelberg.de/user/jtrollma/jt-public.asc

http://www.kip.uni-heidelberg.de/user/jtrollma
----------------------------------------------------------------------------
Petr Klapetek
2014-02-09 21:03:50 UTC
Permalink
Dear Jens,

drop size does not mean volume, it corresponds to amount
by which the local minimum value is increased.

In fact, the value is adaptive and depends on your data
maximum and minimum as dropsize*(max - min)/5000.0.

So no liquid physics is used, unfortunately, but on the other
hand it fits hole of any pixel size.

I hope that I understood all your questions,
Regards,

Petr
Jens Trollmann
2014-02-10 14:04:49 UTC
Permalink
Dear Petr,

thanks for your answer! Then my imagination was totally wrong. To check
if I understood your explanation, does the localizing part of the
algorithm more or less work like that (z assumed as the height value of
a pixel)?:

for (i=1 to number_of_steps, i++)
{
for (every pixel in xy-matrix)
{
follow height gradient [d(z(x,y))/d(x,y)] to local minimum z(xm,ym);

increase height of local minimum z(xm,ym) by factor:
(max(z)-min(z)) * dropsize/5000; //// for dropsize holds: 0 <
dropsize < 1

mark this pixel as lake;
}
check marked pixels if other marked pixels in neighbourhood and mark
connected pixels as 1 lake;
remove lakes smaller than the threshold given;
}

Regards,
Jens
Post by Petr Klapetek
Dear Jens,
drop size does not mean volume, it corresponds to amount
by which the local minimum value is increased.
In fact, the value is adaptive and depends on your data
maximum and minimum as dropsize*(max - min)/5000.0.
So no liquid physics is used, unfortunately, but on the other
hand it fits hole of any pixel size.
I hope that I understood all your questions,
Regards,
Petr
------------------------------------------------------------------------------
Managing the Performance of Cloud-Based Applications
Take advantage of what the Cloud has to offer - Avoid Common Pitfalls.
Read the Whitepaper.
http://pubads.g.doubleclick.net/gampad/clk?id=121051231&iu=/4140/ostg.clktrk
_______________________________________________
Gwyddion-users mailing list
https://lists.sourceforge.net/lists/listinfo/gwyddion-users
Loading...