Main Page   Class Hierarchy   Compound List   File List   Compound Members   File Members  

Conditional_MRF Class Reference

A class representing an Conditional_MRF. More...

#include <Conditional_MRF.hpp>

Inheritance diagram for Conditional_MRF:

Conditional_External_Potts Conditional_Generic_Potts Conditional_Potts List of all members.

Public Methods

virtual ~Conditional_MRF ()
 Destructor.

void Get_subK (vector< uint > &subk)
 Get the subclass vector.

uint Get_K ()
 Get the number of classess/colors ...

uint Get_L ()
 Get the total number of possibilities.

uint Get_N ()
 Get the number of sites.

void Set_Y (vector< uint > const &y)
 Set Y.

void Simulate (vector< double > const &PG_Y, vector< uint > &Z)
 Simulate the Conditional_MRF, one iteration. Gibbs sampler.

void Simulate (uint nbiter, vector< double > const &PG_Y, vector< uint > &Z)
 Simulate the Conditional_MRF, Gibbs sampler.

void Simulate (uint nbiter, vector< uint > const &Y, vector< uint > &Z)
 Simulate the Conditional_MRF, Gibbs sampler.

virtual double H (uint i, uint l, uint k, vector< uint > const &Z)
 Hamiltonian.

virtual double Hmf (uint i, uint l, uint k)
 Mean-field hamiltonian, .

void Compute_PG (uint i, vector< double > const &PG_Yi, vector< uint > const &Z, vector< double > &PG)
 Compute class conditional probabilities at site i given father probabilities PG_Yi and the neighbors Z.

void Compute_PG_cond (uint i, uint l, vector< uint > const &Z, vector< double > &PG)
 Compute class conditional probabilities at site i given father class p and the neighbors Z.

void Compute_PGmf (vector< double > const &PG_Y, vector< double > &P_G)
 Compute conditional probabilities given father probabilities PG_Y and the neighbors Z. mean-field appoximation.

void Compute_PGmf_cond (uint i, uint l, vector< double > &PG)
 Compute conditional probabilities given father class p and the neighbors Z. mean-field appoximation.

void Set_Zmf (vector< double > const &z)
 Set the mean-field neighborhood, .

void Set_Zmf (vector< double > const &z, uint i)
 Set the mean-field neighborhood, at site .

void Get_Zmf (vector< double > &z)
 Get the mean-field neighborhood, .

void Set_Z (vector< uint > const &z)
 Set neighborhood .

virtual void Read_Params (istream &is)
 Read the model parameters from the stream is.

virtual void Write_Params (ostream &os)
 Write the model parameters to the stream os.

virtual uint Degrees_Of_Freedom ()
 Number of free parameters.

virtual void Info ()
 Print some info on the model.


Protected Attributes

Neighborhood_SystemNHS
 Underlying neighborhood system.

vector< uint > subK
 vector of subclasses.

vector< double > Z_mf
 Mean field neighborhood .


Detailed Description

Author:
Juliette Blanchet
Date:
Oct. 2005
Generic Conditional Markov Random Field model. Abstract.


Constructor & Destructor Documentation

Conditional_MRF::~Conditional_MRF   [virtual]
 

Destructor.


Member Function Documentation

void Conditional_MRF::Compute_PGmf vector< double > const &    PG_Y,
vector< double > &    PG
 

Compute

am[out] PG : a vector containing all the probabilities.

void Conditional_MRF::Compute_PGmf_cond uint    i,
uint    l,
vector< double > &    PG
 

Compute

am[out] PG : a vector containing all the probabilities.

uint Conditional_MRF::Degrees_Of_Freedom   [virtual]
 

Estimate the parameters given the state

am[in] Z : current Conditional_MRF state.

Reimplemented in Conditional_External_Potts, Conditional_Generic_Potts, and Conditional_Potts.

uint Conditional_MRF::Get_K  
 

Get the total number of classes

Returns:
the total number of classes in the Conditional_MRF.

uint Conditional_MRF::Get_L  
 

Get the total number of possibilities

Returns:
the total number of possibilities in the Conditional_MRF.

uint Conditional_MRF::Get_N  
 

Get the number of sites.

Returns:
The number of sites.

void Conditional_MRF::Get_subK vector< uint > &    subk
 

Get the vector of subclasses/subcolors.

Returns:
The vector of subclasses/subcolors in the Conditional_MRF.

double Conditional_MRF::H uint    i,
uint    l,
uint    k,
vector< uint > const &    Z
[virtual]
 

Compute the Hamiltonian

Parameters:
i  : a site.
k  : a class.
z  : current state.
Returns:
The value of the hamiltonian.
Abstract. Model-dependent.

Reimplemented in Conditional_External_Potts, Conditional_Generic_Potts, and Conditional_Potts.

double Conditional_MRF::Hmf uint    i,
uint    l,
uint    k
[virtual]
 

Compute the Hamiltonian mean-field approximation, given

Parameters:
i  : a site.
k  : a class.
Returns:
The value of the approximate hamiltonian.
Abstract. Model-dependent.

Reimplemented in Conditional_External_Potts, Conditional_Generic_Potts, and Conditional_Potts.

void Conditional_MRF::Info   [virtual]
 

Print some info on the model.

Reimplemented in Conditional_External_Potts, Conditional_Generic_Potts, and Conditional_Potts.

void Conditional_MRF::Read_Params istream &    is [virtual]
 

Read the model parameters from the stream is.

Reimplemented in Conditional_External_Potts, Conditional_Generic_Potts, and Conditional_Potts.

void Conditional_MRF::Set_Z vector< uint > const &    z
 

Set the mean-field neighborhood, given Conditional_MRF current state .

am[in] z : current Conditional_MRF state.
Define|Set neighborhod conditions.

void Conditional_MRF::Set_Zmf vector< double > const &    z,
uint    i
 

Set the mean-field neighborhood, , at site i

am[in] z : vector of doubles.
am[in] i : a site.

void Conditional_MRF::Set_Zmf vector< double > const &    z
 

Set the mean-field neighborhood,

am[in] z : vector of doubles.

void Conditional_MRF::Simulate uint    nbiter,
vector< uint > const &    Y,
vector< uint > &    Z
 

Simulation algorithm given Y. Gibbs Sampler. N iterations over all the sites.

am[in] nbiter : number of iterations.
am[in] Z : current state.
am[out] Z : new state

void Conditional_MRF::Simulate uint    nbiter,
vector< double > const &    PG_Y,
vector< uint > &    Z
 

Simulation algorithm given PG_Y. Gibbs Sampler. N iterations over all the sites.

am[in] nbiter : number of iterations.
am[in] Z : current state.
am[out] Z : new state

void Conditional_MRF::Simulate vector< double > const &    PG_Y,
vector< uint > &    Z
 

Simulation algorithm. Gibbs Sampler. 1 iteration over all the sites.

am[in] Z : current state.
am[out] Z : new state

void Conditional_MRF::Write_Params ostream &    os [virtual]
 

Write the model parameters to the stream os.

Reimplemented in Conditional_External_Potts, Conditional_Generic_Potts, and Conditional_Potts.


The documentation for this class was generated from the following files:
Generated on Tue Nov 8 14:55:48 2005 for NEM by doxygen1.2.18