imaging::MumfordShahEnergy< shape_t > Class Template Reference
[Segmentation Module]

Simplified Mumford-Shah energy for arbitrary shape classes. More...

#include <MumfordShahEnergy.hpp>

Inheritance diagram for imaging::MumfordShahEnergy< shape_t >:

imaging::DifferentiableEnergyInterface imaging::ShapeEnergyInterface< shape_t > imaging::EnergyInterface imaging::EnergyInterface

List of all members.

Public Member Functions

template<class const_accessor_t>
 MumfordShahEnergy (const const_accessor_t &image, const shape_t &initial_shape, float_t beta, std::size_t n_integration_points)
ublas::vector< float_t > & current_argument ()
float_t current_energy () const
std::size_t dimension () const
const shape_t & current_shape () const
const ublas::vector< float_t > & current_gradient () const
void set_argument ()
void set_argument_with_gradient ()


Detailed Description

template<class shape_t>
class imaging::MumfordShahEnergy< shape_t >

Simplified Mumford-Shah energy for arbitrary shape classes.

This class template implements the simplified version of the Mumford-Shah functional for shapes of the type shape_t. The template parameter shape_t must implement ShapeInterface.

The simplified Mumford-Shah functional reads as follows:

\[ I_\beta^{\textrm{SMS}}(\gamma) = \int_{\mathcal{I}(\gamma)}\big(u_1(\gamma) - f\big)^2 d x + \int_{\mathcal{O}(\gamma)} \big(u_2(\gamma) - f\big)^2 d x + \beta |\gamma|_2^2\,, \]

where

\[ u_1(C) = \frac1{|\mathcal{I}(\gamma)|}\int_{\mathcal{I}(\gamma)}f d x \quad{\textrm{and}} \quad u_2(C) = \frac1{|\mathcal{O}(\gamma)|}\int_{\mathcal{O}(\gamma)}f d x\,. \]

Upon construction a MumfordShah object is initialized to an Image $u$ and an initial shape $\mu$.

Then, the MumfordShah objects maps a vector $v$ to the corresponding energy as follows:

\[ v \mapsto I_\beta^{\textrm{SMS}}\big(\textrm{Exp}_\mu(v)\big)\,. \]


Constructor & Destructor Documentation

template<class shape_t>
template<class const_accessor_t>
imaging::MumfordShahEnergy< shape_t >::MumfordShahEnergy ( const const_accessor_t &  image,
const shape_t &  initial_shape,
float_t  beta,
std::size_t  n_integration_points 
) [inline]


Member Function Documentation

template<class shape_t>
ublas::vector<float_t>& imaging::MumfordShahEnergy< shape_t >::current_argument (  )  [inline, virtual]

Access the current argument of the energy. In general the user should not resize the current argument!

Implements imaging::EnergyInterface.

template<class shape_t>
float_t imaging::MumfordShahEnergy< shape_t >::current_energy (  )  const [inline, virtual]

Returns the current energy. This function should not actually compute the current energy but return the cached result of the last call to set_argument()!

Implements imaging::EnergyInterface.

template<class shape_t>
std::size_t imaging::MumfordShahEnergy< shape_t >::dimension (  )  const [inline, virtual]

Returns the dimension the class expects as input data. The function current_argument() will return a vector of this dimension and the user should not change the size of this vector!

Implements imaging::EnergyInterface.

Referenced by imaging::MumfordShahEnergy< shape_t >::set_argument_with_gradient().

template<class shape_t>
const shape_t& imaging::MumfordShahEnergy< shape_t >::current_shape (  )  const [inline, virtual]

Returns the current shape. This function should not actually compute the current shape but return the cached result of the last call to set_argument()!

Implements imaging::ShapeEnergyInterface< shape_t >.

template<class shape_t>
const ublas::vector<float_t>& imaging::MumfordShahEnergy< shape_t >::current_gradient (  )  const [inline, virtual]

Returns the current gradient. This function should not actually compute the current energy but return the cached result of the last call to set_argument()!

Implements imaging::DifferentiableEnergyInterface.

template<class shape_t>
void imaging::MumfordShahEnergy< shape_t >::set_argument (  )  [inline, virtual]

Compute the energy value corresponding to the current argument. This is where the main work of the energy evaluation should be done.

Implements imaging::EnergyInterface.

template<class shape_t>
void imaging::MumfordShahEnergy< shape_t >::set_argument_with_gradient (  )  [inline, virtual]

Compute the energy value and the gradient corresponding to the current argument. This is where the main work of the energy evaluation should be done. In contrast to set_argument() this function also computes the gradient. I.e. in general it is more expensive than set_argument().

Implements imaging::DifferentiableEnergyInterface.

References imaging::MumfordShahEnergy< shape_t >::dimension(), and imaging::square().

Referenced by imaging::MumfordShahEnergy< shape_t >::MumfordShahEnergy().


The documentation for this class was generated from the following file:

Generated on Tue Feb 10 10:01:31 2009 for imaging2 by  doxygen 1.5.5