精华内容
下载资源
问答
  • Level Set

    2021-03-06 10:24:00
    而对于初始的二维曲线(两个参数方程表示一条二维平面曲线),把他转变成三维的level set 就会是一个曲面(二元函数)上,某个level下的(一般选择的是level=0,也就是 f(x,y)=0),所有点的(x,y)坐标的集合...

    曲线演化

    一条曲线上的每个点根据不同的速度和方向运动最终演变成另外一条曲线 。

    曲线演化理论的应用  -- -- 通过要分割的图像确定曲线演化的速度和方向

      以图像分割为例子,曲线演化的过程就是实现图像分割的过程,假如我们要对一张图像进行分割,首先在图像上绘制一条曲线,然后我们的目标是将原始曲线的演化成可以包住分割目标的曲线。演化的两个关键点就是曲线上每个点的速度和方向。我们希望达到的效果是当这条曲线基本包住目标区域的时候曲线上的点停止运动。要达到这样的效果,曲线上距离目标位置远的点就需要加速运动,近的点运动的相对慢一些,因为图像的边缘点特征是灰度值的梯度比其他区域更大一些,所以当前点的运动速度的大小应该与该点对应梯度的大小成反比。

    Level Set水平集  --曲线演化的实现方法

     核心思想:研究问题转变成更高一维空间函数(水平集函数)的零水平集。

    当我们要追踪某一曲线(曲面)的演化过程,实际上就等价于追踪更高一维曲面的演化过程。

    举例来说:

    一维曲线上的两个点X1和X2表示: X1 = -1, X2 = 1

    转变成一种集合表示形式,也即转变成更高一维度的零水平集(level set),也就是在二维坐标空间中X1, X2可以表示成函数y = f(x) = x^{2}=1时对应的x的取值集合{-1, 1},这里的y 就是level 的取值。

    而对于初始的二维曲线(两个参数方程表示一条二维平面曲线),把他转变成三维的level set 

     

    就会是一个曲面(二元函数)上,某个level下的(一般选择的是level=0,也就是 f(x,y)=0),所有点的(x,y)坐标的集合(图中红色的为曲线,这些点的z坐标均为零):

     

     

    将图像和曲线看作两个图层,假设曲线是二维的,那么按照水平集方法的思想,可以看成是f(x,y)=0(level = 0)的三维立体,初始曲线level = 0,通过不断对蓝色平面进行上下连续移动,level始终满足等于0()。

    移动的过程图可以类比地形等高线,最终回到level =  0的状态,就是最终的目标曲线。

     

     

     

     

    改变曲线形状的速度方向是法线方向的,而切线方向的速度是不改变曲线的形状的

     

     

     

    转载:https://www.zhihu.com/question/22608763

    展开全文
  • level set methods

    2018-12-20 09:50:25
    level set 讲的比较清楚 Level Set Methods and Dynamic Implicit Surfaces
  • code of Levelset

    2018-12-30 14:24:04
    levelset.
  • Level set mesher

    2020-12-09 05:56:26
    If some vertices are outside of the level set, they are projected onto the level set using either a simple linear projection or a full nonlinear projection, controled by an ... methods of LevelSet...
  • Levelset module

    2021-01-01 18:08:00
    <div><p>I am finally merging the level set capability, the basics of which have been done for some time. However, I was waiting for a variety of changes to MooseDocs to document the module, this PR ...
  • Level set bounds

    2020-12-08 21:46:59
    <div><p>Improved LevelSet: Now the user can specify a bounding box by using the setLowerBound()/setUpperBound() methods. The level set is cliped by this bounding box, ie the contains() method will ...
  • LevelSet原理

    2012-02-09 13:48:58
    J.A. SETHIAN 著的"Level Set Method: An Act of Violence" 。很短的几页,生动形象的介绍了Level Set的基本思想,是Level Set的入门好参考。
  • level set 编程书籍

    2018-01-16 10:24:15
    level set 用于界面捕捉及图像处理等多种应用领域,是比较方便快捷有效的界面捕捉方法。
  • 基于Level Set的海岸线检测
  • level set matlab

    2011-10-17 15:46:25
    此资源是一份用matlab编写的level set源代码,可以执行。希望能帮助到同行人士。
  • Adaptive level set for fluid surface tracking.
  • <p>For efficient sparse factorization and solve, it is better to use level set scheduling as kokkos tasking does not allow user-defined team size yet (it is fixed as 32 and it is too small)....
  • Level set作为一种有效的界面追踪方法,已经被广泛地应用到单相流的自由表面追踪或多相流的交界面追踪.快速粒子level set方法(FPLS)是一种改进的level set方法,既具有较高的界面追踪精度,又有较高的计算效率.将...
  • 半导体材料综合分析 LevelSet分析法,空穴半导体材料综合分析 LevelSet分析法,空穴半导体材料综合分析 LevelSet分析法,空穴
  • 李纯明老师的level set代码,matlab写的,对应论文Distance Regularized Level Set Evolution and Its Application to Image Segmentation
  • Level Set方法简介

    2015-04-30 14:28:00
    转载]LevelSet方法简介(转载)Level Set方法是美国数学家Osher(加州大学洛杉矶分校)和Sethian(加州大学伯克利分校)合作提出的。后者因为对Level Set的贡献获得了去年美国数学会与工业应用数学会联合颁发的维纳奖。...

    转载]Level Set方法简介(转载)

    Level Set方法是美国数学家Osher(加州大学洛杉矶分校)和Sethian(加州大学伯克利分校)合作提出的。后者因为对Level Set的贡献获得了去年美国数学会与工业应用数学会联合颁发的维纳奖。遗憾的是这两位Level Set的开创者现在正为争夺Level Set的名誉而对簿公堂。

    Level Set方法是他们在98年文章“Front Propagation with Curvature Depedent Speed: Algorithms Based on Hamilton-Jacobi Formulation"中第提出的。这个方法提出以后被成功地应用于流体力学,计算机图形学,材料科学等领域。应用于图像处理和计算机视觉始于93年Caselles等人和95年Malladi等人的两篇著名文章。他们用Level Set来表示Snakes,想法很简单:一个平面上的曲线可以表示成一个二元函数z=f(x,y)的零点集合(Zero Level Set),既这个二元函数z=f(x,y)所表示的三维曲面与xy平面的交线。更一般地,任何N维曲面都可以表示为一个N+1维曲面与一个N维超平面的交集,或称为N+1维曲面在一个N维超平面上的投影。相对最早的Snake(用参数化的曲线,所以也叫parametric active contour),用level set表示的活动曲线叫着Geometric Active Contours。

    用二维曲面与二维平面的交线表示曲线,这在微积分甚至中学数学里都是很平凡的。但是,当我们要描述曲线运动的时候,用Level Set表示曲线就有很明显的优点。比如说,几条曲线在运动中merge成一条曲线,或一条曲线分裂成几条曲线,这样的拓扑变化是不可能表示成一条连续的参数化曲线的运动。原因很简单,一条连续的参数化曲线是用一个一元连续函数来卞表示的,它显然不能表示几条分开的曲线(这与连续性矛盾)。

    然而,以上所说的曲线的拓扑变化却可以简单地表示成一个连续变化的的曲面与一个固定的平面的交线。这个曲面本身可以不发生拓扑变化,它可以始终是一个连续的二元函数z=f(x,y)的图象。这样,复杂的曲线运动就可以简单地表示成一个更高一维的函数的演化,这可以用一个发展方程(evolution equation)来描述,数学里已经有很多工具可以用了。


    再接着说说level set吧。我这次参加CVPR,遇到很多人都说level set很难。我甚至还听说有个做snake很有名的教授对level set很反感。说实话,我在去年开始实现别人的level set方法时,也对level set越来越讨厌。原因是:现有的level set方法实现跟理论不一致(这在Gomes和Faugeras的文章里已经指出),需要搀杂不少remedies,比如最令人讨厌的re-initialization。还有一些步骤,比如velocity extension,都不是让人赏心悦目的东西。这些步骤就象长在人身上的赘肉或瘤,也许是良性的,但总是让人看着极不舒服,甚至怕它恶化。

    但是,还是有些人能把这样复杂而且不是那么优美的方法实现出来,而且用得不错,具有其它很多方法不具备的优点,比如让曲线自然地split和merge。象任何一种理论和方法一样,尽管有缺点(比如re-initialization),但毕竟大家还是看到了它的巨大潜力。所以这还是成为一个很热的研究方向。

    其实在我实现的别人的level set方法里面,很容易看到,即使对没有任何noise的图象,比如一个bianry的图象,里面只有一个简单的object(比如圆),level set function(LSF)的演化都很不稳定。问题出在对连续函数和PDE的离散化,还有就是speed function,不仅取决于level set本身,还取决于图象。即使在没noise的情况下,speed function在object boundary和其它地方是很不一样的,导致了不同level set的运动很不均匀,有的地方快,有的地方慢。所以我们会看到 LSF的等高线(即level sets)在有的地方很密,有的地方很稀,这会给进一步计算带来误差,甚至很快就发散了。这就是原有的level set方法需要每迭带几步停下来做re-initialization的原因。

    有了re-initialization这样的remedy,这些方法对noise还是相当robust的,应该说比别的方法都robust。另外,象velocity extension这样的步骤,也对不同level set的运动起到更均匀的作用,使得LSF的演化更加稳定。

    这只是对noise的robust。整个演化过程的稳定性和准确性还很依赖于什么时候停下来做reinitialization,怎么做,等等。

    如果能找到一种方法,它在演化LSF的同时,又能自动维持LSF的良好性质,比如不太平也不太陡(最理想的就是signed distance function,它的坡度是45度,即切平面跟z轴的夹角是45度,不平不陡,正中间)。换句话说,我希望LSF的演化既是让Zero Level Set运动的过程,又是不断保持甚至提高整个LSF的良好形状的过程。这在现有的level set方法里面都不具备。我正是基于这个考虑,想到了我的方法(有兴趣请看我的CVPR文章)。

    现在再回答几个问题。Level set方法并不需要你懂很多微分几何和微分方程的理论。对于前者,你只要知道怎么用隐函数来计算曲线的法方向和曲率。这在很多level set的文章或书中都有很易懂的介绍。对于微分方程,主要是知道怎么离散化去数值解。

    对于Level Set的预备知识,我还得提一下变分法。也不是所有Level Set方法都需要变分法的。比如Osher和Sethian最初提出level Set时就不需要。基于变分法的level set方法,被称做variational level set methods。我的方法就是variational level set。

    在很多高等数学的课本里都有变分法的基本内容,这就够用了。关键是学会怎么计算泛函的导数。首先要知道,泛函就是函数的函数,即泛函的变量本身就是一个函数。有了泛函的导数,就得到了所谓的gradient flow。直观的说,一个泛函的gradient flow就是这个泛函的变量(一个函数)朝着这个泛函的极小值点运动的过程。这跟普通函数求极小值的最速下降法(steepest decsent)是相似的。




    转载于:https://www.cnblogs.com/wolowitz/p/4468821.html

    展开全文
  • VOF法与Level Set法的比较,汪迎春,汪德爟,VOF法和Level Set法同属于界面捕获类算法,有很多相似之处。本文对两种方法进行了详细的介绍,并用剪切流场进行了测试,比较分析了两
  • LevelSet toolbox

    2008-05-19 18:58:27
    LevelSet的Matlab工具箱,里面有详细的说明文档
  • levelset 解释

    千次阅读 2013-10-06 17:18:08
    Herve Lombaert Research Projects Algorithms School Presentations Schedule Level set method: ...Here the basics of the level set method is explained, this is not an advanced tutoria
    Herve Lombaert

    Level set method: Explanation

    Here the basics of the level set method is explained, this is not an advanced tutorial. For quite some time, I was afraid of the level set method. I am still not sure why I first got scared. The level set method is just plain easy to understand: there is a surface, it intersects a plane, that gives us a contour and that's it. With image segmentation, the surface is updated with forces derived from the image. In this document, I follow this path: what is the problem, what was done to solve it and where the limitation was, and then the miracle solution with some pretty pictures.

    Tracking interfaces

    First, let us imagine water falling from the top of a hill. The goal is to track the water front while it's moving down the hill. The figure below shows a map of a V-shaped water fall with water motion shown in red.

    Figure: Elevation map of a V-shaped water fall, black is on top, white is down the fall. Arrows show the Water motion.
    Image motion

    The question now is where is the water front at a given time t ?

    Explicit contours

    One way is to keep track of a few points, advance them in the normal direction to the front (the red arrows), and guess where the front ends up. The figure below shows a step of this technique.

    Figure: Evolution of a set of points on the front at time t=0, and at time t=1
    Image tracking

    Evolving explicitly the front with a set of points may sound a good solution, but there are a couple of drawbacks that may want you to not use this technique.

    With our last example of a V-shaped propagating front, corners can end up in an unknown state. The figure below illustrates such a state after one iteration.

    Figure: Front evolution of a corner into an unknown state
    Image tracking-v-shape

    Also, if the front is expanding, the initial set of points may not be sufficient enough to define the evolving front. Points should be inserted or removed in the front when it is collapsing, and distance between points should be kept small enough for a smooth front. Such a mechanism could be troublesome during implementation.

    Topology change requires further care during implementation (eg. split and merge of fronts). In our hill example, let us now imagine valleys and water moving from the top down into the valleys. The figure below illustrates such a scenario. The challenge is how to insert or remove points during a topology change.

    Figure: Two valleys, black is on top, white is down the fall. (a) Initial water fronts on top of a valley, (b) spliting and merging of water fronts
    Image tracking-valley-n-0 Image tracking-valley-n-50
    (a) t=0 (b) t=50

    Tracking the front with explicit contours is intuitive but can get troublesome during implementation.

    Implicit contours

    The idea of evolving a surface ($\phi$) instead of a front (C) was proposed, and the front is defined to be all points where the surface has no height ($\phi = 0$). The front is then defined implicitly as the zero level set $\phi = 0$. The figure below shows how the contour is extracted from the evolving surface.

    Figure: Here the zero level set of the surface is a square
    Image levelset-square

    When the surface evolves, cups can appear, they can later narrow, or disappear. The zero level set shows contours spliting and merging as illustrated in the figure below where the plane at z=0 represents the map of our valley. The intersection of the surface $\phi$ with the plane creates the implicit contour. Merging and spliting are here handled naturally by the surface motion.

    Figure: The evolving front in red is known by taking the zero level set of a surface $\phi$
    Image levelset-n-50 Image levelset-n-52
    (a) t=50, beginning of merging (b) t=52, end of merging
    Image levelset-n-90 Image levelset-n-120
    (c) t=90, beginning of spliting (d) t=120, end of spliting

    No extra care is needed for topology change. This looks like an interesting idea, the question is now: what is the function $\phi$?

    Level set equation

    Let us look at the math behind this idea. A point $\boldmath {x} = (x,y)$ belonging to a front evolves over time so that $\boldmath {x}(t)$ is its position over time. At any time t, for each point $\boldmath {x}(t)$ on the front the surface has by definition no height, thus:


    \begin{eqnarray*}\phi(\boldmath {x}(t),t) & = & 0\end{eqnarray*}


    The question still remains: what is the function $\phi(\boldmath {x}(t),t)$? It can actually be anything we want as long as its zero level set gives us the contour. For example, a previous figure () showed an initial squared contour. The surface height is equal to the distance from (x,y) to the closest point on the contour, so that $\phi(x,y,t=0) = \pm d$, with distance d positive outside the contour, and d negative inside it. So the initial $\phi$ can actually be any arbitrary function as long as its zero level set matches the initial contour

    Given an initial $\phi$ at t=0, it would be possible to know $\phi$ at any time t with the motion equation$\frac{\partial\phi}{\partial t}$. For that, the chain rule gives us:


    \begin{eqnarray*}\frac{\partial\phi\left(\boldmath {x}(t),t\right)}{\partial t}......\phi}{\partial \boldmath {x}(t)}\boldmath {x}_t + \phi_t & = & 0\end{eqnarray*}


    Here, recall that $\frac{\partial\phi}{\partial \boldmath {x}} = \nabla\phi$. Also, the speed $\boldmath {x}_t$ is given by a force F normal to the surface, so$\boldmath {x}_t = F\left(\boldmath {x}(t)\right) \boldmath {n}$ where $\boldmath {n} = \frac{\nabla\phi}{\vert\nabla\phi\vert}$. The previous motion equation can be rewriten with:


    \begin{eqnarray*}\phi_t + \nabla\phi \boldmath {x}_t & = & 0\\\phi_t + \nabla......bla\phi\vert} & = & 0\\\phi_t + F \vert\nabla\phi\vert & = & 0\end{eqnarray*}


    This last equation defines the motion of $\phi$. Given $\phi$ at time t=0, and its motion over time, it is now possible to know $\phi(x,y,t)$ at any time t by evolving the initial $\phi(x,y,t=0)$ over time. This answers our initial question, we now know what $\phi$ is.

    An interesting feature that comes with $\phi$ is that it is possible to get the surface curvature with:


    \begin{eqnarray*}\kappa & = & \nabla \frac{\nabla\phi}{\vert\nabla\phi\vert} ......i_{xy}\phi_x\phi_y + \phi_{yy}\phi_x^2}{(\phi_x^2+\phi_y)^{1/2}}\end{eqnarray*}


    This could be useful to control the front smoothness.

    Implementation

    In the computer world, images have pixels and functions need to be discretized. That means $\phi_t$ will be evaluated at pixel (i,j) by $\frac{\phi(i,j,t+\Delta t) - \phi(i,j,t)}{\Delta t}$. The gradient will be evaluated by a finite difference scheme, for example with:


    \begin{eqnarray*}\nabla^{+x}(i,j) = max\left[0,\Delta^{-x}\phi(i,j)\right]^2 + ......2 + min\left[0,\Delta^{-x}\phi(i,j)\right]^2, \textrm{when} F<0.\end{eqnarray*}


    Here, $\Delta^{-x}\phi$ or $\Delta^{+x}\phi$ is the left or the right side finite difference for a given point. This is illustrated in the figure below. The gradient is computed differently depending on the front direction and a finite difference scheme takes account of that.

    Figure: left or right side finite difference (eg. how to evaluate $\vert\nabla\phi\vert$)
    Image phi-difference

    The previous motion equation now becomes:


    \begin{eqnarray*}\frac{\phi(i,j,t+\Delta t) - \phi(i,j,t)}{\Delta t} + max[F,0] \nabla^{+x}(i,j) + min[F,0] \nabla^{-x}(i,j) & = & 0\end{eqnarray*}


    From there, updating the surface $\phi(i,j)$ is done with:


    \begin{eqnarray*}\phi(i,j,t+\Delta t) & = & \phi(i,j,t) - \Delta t \left[ max[F,0] \nabla^{+x}(i,j) + min[F,0] \nabla^{-x}(i,j) \right]\end{eqnarray*}


    When computing the curvature, it depends only on the surface $\phi$, so central differences can be used. They are:


    \begin{eqnarray*}\phi_{xx}(i,j) &=& \left(\phi(i+1,j)-\phi(i,j)\right)-\left(\p......t)\\\phi_y &=& \frac{1}{2}\left(\phi(i,j+1)-\phi(i,j-1)\right)\end{eqnarray*}


    The curvature is then computed numerically with:


    \begin{eqnarray*}\kappa(i,j) &=& \frac{\phi_{xx}\phi_y^2 - 2\phi_y\phi_x\phi_{x......- 2\phi_y\phi_x\phi_{xy} + \phi_{yy}\phi_x^2}{\phi_x^2+\phi_y^2}\end{eqnarray*}


    To keep a front smooth, high curvature should be penalized. That means, rather than decreasing $\phi$ in order to have the zero level set expanding, high curvature will reverse the front motion. Updating $\phi(i,j)$ with the curvature could be:


    \begin{eqnarray*}\phi(i,j,t+\Delta t) & = & \phi(i,j,t) - \Delta t \left[ max(F......) \nabla^{-x}(i,j) \right] + \Delta t \left[ \kappa(i,j) \right]\end{eqnarray*}


    Results

    Given an initial arbitrary $\phi$, for example the distance transform of an initial contour, and a numerical scheme for the motion equation $\frac{\partial\phi}{\partial t}$, it is possible to show some examples of contour evolution.

    First a simple example of a drop of water exanding (F=1 everywhere) with an obstacle on its path (where F=0). The water front should be stopped by the obstacle and later be perturbed by the obstacle. This is shown in the figures below.

    Figure: An initial circle expands where F=1 and is perturbed by an obstacle where F=0
    Image circle-1 Image circle-2 Image circle-3
    (a) initial contour (b) stoped by an obstacle (c) later perturbation

    Then, a slightly more complex form illustrated below. The initial contour is still a circle, and the forces applied to it is positive (F=1) inside a form, and it is negative (F=-1) outside it. The contour should then be attracted into the form. Also notice the front split between the two regions. Here, the surface $\phi$ is also shown to explain how this split is formed.

    Figure: An initial circle expands inside the form where F>0 and collapses outside the form (F<0), the corresponding $\phi$ surface is also shown with a plane intersecting at z=0
    Image form-1 Image form-2 Image form-3
    (a) initial contour (b) contour split (c) two new contours

    After having shown how constant forces act on $\phi$, the next example shows a shape collapsing under its curvature. Here the force is equal to the curvature $\kappa$ of the surface $\phi$.

    Figure: A form collapsing under its curvature
    Image annealing-1 Image annealing-2 Image annealing-3
    (a) initial contour (b) intermediate step (c) before desappearing

    Now the fun begins with real pictures. Instead of using constant positive or negative forces, with or without curvature, the force is derived from an image. We can think of a contour stopped at the edges of an object. The force should then be high inside the object (we want the curve expanding inside an object), and it should be low close to the edges (we want the curve to stop at the edges). The gradient of an image shows where the edges are.

    Figure: Image of a heart with its corresponding gradient
    Image heart Image heart-gradient  
    (a) image I (b) its gradient $\vert\nabla I\vert$  

    The force to be used could be the inverse of the previous gradient image $\nabla I$, or it could be the gaussian of it:


    \begin{eqnarray*}F(i,j) &=& \frac{1}{1+\lambda \vert\nabla I(i,j)\vert}\\F(i,j) &=& e^{-\frac{\vert\nabla I(i,j)\vert^2}{2\sigma^2}}\end{eqnarray*}


    Here $\lambda$ or $\sigma$ are parameters controlling how penalizing the edges should be. Below is an evolving contour using the inverse of the gradient image.

    Figure: Contour evolution with a real image
    Image heart-1 Image heart-2 Image heart-3
    (a) initial contour (b) intermediate step (c) stopped by the edges

    At this point, you should at least understand that level set method is all about evolving a surface instead of the real contour. That makes the beauty of this method. Level sets have applications in many fields. See google for further reading.

    Bibliography

    1
    Osher S., Sethian J.A., Fronts Propagating with Curvature-Dependent Speed: Algorithms Based on Hamilton-Jacobi Formulations (Journal of Computational Physics, 79(1), page 12-49, 1988).

    2
    Kass M., Witkin A., Terzopoulos D., Snakes - Active Contour Models (International Journal of Computer Vision, 1(4), page 321-331, 1987)



    Herve Lombaert 2006-03-01
    展开全文
  • This book covers the state-of-the-art approaches for medical imaging segmentation based on the level set technique that was implemented by Osher and Sethian. The level set technique mainly relies on ...
  • 首先利用平滑和细化算法对西夏影印文献进行了预处理,然后利用Level set方法对影印文献中的西夏字进行了轮廓提取。Level Set演化函数在空间方向上采用了四阶紧致差分逼近式离散,计算过程中加入了窄带算法及全局优化...
  • PCNN-Based Level Set Method of Automatic Mammographic Image Segmentation
  • level set method new

    2010-04-11 14:01:35
    level set based image segmentation with multiple regions
  • ve started migrating the Fortran code that computes the levelset function (i.e. the code that's currently in <code>Src/EB/AMReX_EB_levelset_F.F90</code> and <code>Src/EB/AMReX_EB_geometry.F90). ...
  • <div><p>it seems to me that we could support higher order meshes with the levelset function. As soon as the levelset stays P_1 and we have access to the vertices of the simplices and the hypercubes, I...
  • The level set method is commonly used to address image noise removal. Existing studies concentrate mainly on determining the speed function of the evolution equation. Based on the idea of a Canny ...
  • Segmentation of Coronary Artery Using Region Based Level Set with Edge Preservation
  • Level set model for water region segmentation in synthetic aperture radar images
  • 这本书是创始人之一Osher写的,这本书是论述Level Set的最完整的书籍之一,更偏重于数值化的高精度解,应用领域涉及图像处理以及计算物理。

空空如也

空空如也

1 2 3 4 5 ... 20
收藏数 41,742
精华内容 16,696
关键字:

levelset