C# Class Accord.Statistics.Models.Markov.ContinuousHiddenMarkovModel

Inheritance: HiddenMarkovModelBase, IHiddenMarkovModel
Show file Open project: atosorigin/Kinect Class Usage Examples

Public Methods

Method Description
ContinuousHiddenMarkovModel ( ITopology topology, IDistribution emissions ) : System

Constructs a new Hidden Markov Model with discrete state probabilities.

ContinuousHiddenMarkovModel ( ITopology topology, int symbols ) : System

Constructs a new Hidden Markov Model with discrete state probabilities.

ContinuousHiddenMarkovModel ( double transitions, IDistribution emissions, double probabilities ) : System

Constructs a new Hidden Markov Model.

ContinuousHiddenMarkovModel ( double transitions, double emissions, double probabilities ) : System

Constructs a new Hidden Markov Model.

ContinuousHiddenMarkovModel ( int states, IDistribution emissions ) : System

Constructs a new Hidden Markov Model.

ContinuousHiddenMarkovModel ( int states, int symbols ) : System

Constructs a new Hidden Markov Model with discrete state probabilities.

Decode ( Array observations, bool logarithm, double &probability ) : int[]

Calculates the most likely sequence of hidden states that produced the given observation sequence.

Decoding problem. Given the HMM M = (A, B, pi) and the observation sequence O = {o1,o2, ..., oK}, calculate the most likely sequence of hidden states Si that produced this observation sequence O. This can be computed efficiently using the Viterbi algorithm.

Decode ( Array observations, double &probability ) : int[]

Calculates the most likely sequence of hidden states that produced the given observation sequence.

Decoding problem. Given the HMM M = (A, B, pi) and the observation sequence O = {o1,o2, ..., oK}, calculate the most likely sequence of hidden states Si that produced this observation sequence O. This can be computed efficiently using the Viterbi algorithm.

Evaluate ( Array observations ) : double

Calculates the probability that this model has generated the given sequence.

Evaluation problem. Given the HMM M = (A, B, pi) and the observation sequence O = {o1, o2, ..., oK}, calculate the probability that model M has generated sequence O. This can be computed efficiently using the either the Viterbi or the Forward algorithms.

Evaluate ( Array observations, bool logarithm ) : double

Calculates the probability that this model has generated the given sequence.

Evaluation problem. Given the HMM M = (A, B, pi) and the observation sequence O = {o1, o2, ..., oK}, calculate the probability that model M has generated sequence O. This can be computed efficiently using the either the Viterbi or the Forward algorithms.

Private Methods

Method Description
convert ( Array array ) : double[][]

Converts a univariate or multivariate array of observations into a two-dimensional jagged array.

Method Details

ContinuousHiddenMarkovModel() public method

Constructs a new Hidden Markov Model with discrete state probabilities.
public ContinuousHiddenMarkovModel ( ITopology topology, IDistribution emissions ) : System
topology ITopology /// A object specifying the initial values of the matrix of transition /// probabilities A and initial state probabilities pi to be used by this model. ///
emissions IDistribution /// The initial emission probability distribution to be used by each of the states. ///
return System

ContinuousHiddenMarkovModel() public method

Constructs a new Hidden Markov Model with discrete state probabilities.
public ContinuousHiddenMarkovModel ( ITopology topology, int symbols ) : System
topology ITopology /// A object specifying the initial values of the matrix of transition /// probabilities A and initial state probabilities pi to be used by this model. ///
symbols int The number of output symbols used for this model.
return System

ContinuousHiddenMarkovModel() public method

Constructs a new Hidden Markov Model.
public ContinuousHiddenMarkovModel ( double transitions, IDistribution emissions, double probabilities ) : System
transitions double The transitions matrix A for this model.
emissions IDistribution The emissions matrix B for this model.
probabilities double The initial state probabilities for this model.
return System

ContinuousHiddenMarkovModel() public method

Constructs a new Hidden Markov Model.
public ContinuousHiddenMarkovModel ( double transitions, double emissions, double probabilities ) : System
transitions double The transitions matrix A for this model.
emissions double The emissions matrix B for this model.
probabilities double The initial state probabilities for this model.
return System

ContinuousHiddenMarkovModel() public method

Constructs a new Hidden Markov Model.
public ContinuousHiddenMarkovModel ( int states, IDistribution emissions ) : System
states int The number of states for the model.
emissions IDistribution A initial distribution to be copied to all states in the model.
return System

ContinuousHiddenMarkovModel() public method

Constructs a new Hidden Markov Model with discrete state probabilities.
public ContinuousHiddenMarkovModel ( int states, int symbols ) : System
states int The number of states for this model.
symbols int The number of output symbols used for this model.
return System

Decode() public method

Calculates the most likely sequence of hidden states that produced the given observation sequence.
Decoding problem. Given the HMM M = (A, B, pi) and the observation sequence O = {o1,o2, ..., oK}, calculate the most likely sequence of hidden states Si that produced this observation sequence O. This can be computed efficiently using the Viterbi algorithm.
public Decode ( Array observations, bool logarithm, double &probability ) : int[]
observations System.Array A sequence of observations.
logarithm bool True to return the log-likelihood, false to return /// the likelihood. Default is false (default is to return the likelihood).
probability double The state optimized probability.
return int[]

Decode() public method

Calculates the most likely sequence of hidden states that produced the given observation sequence.
Decoding problem. Given the HMM M = (A, B, pi) and the observation sequence O = {o1,o2, ..., oK}, calculate the most likely sequence of hidden states Si that produced this observation sequence O. This can be computed efficiently using the Viterbi algorithm.
public Decode ( Array observations, double &probability ) : int[]
observations System.Array A sequence of observations.
probability double The state optimized probability.
return int[]

Evaluate() public method

Calculates the probability that this model has generated the given sequence.
Evaluation problem. Given the HMM M = (A, B, pi) and the observation sequence O = {o1, o2, ..., oK}, calculate the probability that model M has generated sequence O. This can be computed efficiently using the either the Viterbi or the Forward algorithms.
public Evaluate ( Array observations ) : double
observations Array /// A sequence of observations. ///
return double

Evaluate() public method

Calculates the probability that this model has generated the given sequence.
Evaluation problem. Given the HMM M = (A, B, pi) and the observation sequence O = {o1, o2, ..., oK}, calculate the probability that model M has generated sequence O. This can be computed efficiently using the either the Viterbi or the Forward algorithms.
public Evaluate ( Array observations, bool logarithm ) : double
observations Array /// A sequence of observations. ///
logarithm bool /// True to return the log-likelihood, false to return /// the likelihood. Default is false. ///
return double