Accord.Statistics.Models.Markov.Learning.BaseBaumWelchLearning.Run C# (CSharp) Méthode

Run() protected méthode

Runs the Baum-Welch learning algorithm for hidden Markov models.
Learning problem. Given some training observation sequences O = {o1, o2, ..., oK} and general structure of HMM (numbers of hidden and visible states), determine HMM parameters M = (A, B, pi) that best fit training data.
protected Run ( Array observations ) : double
observations System.Array /// The sequences of univariate or multivariate observations used to train the model. /// Can be either of type double[] (for the univariate case) or double[][] for the /// multivariate case. ///
Résultat double
        protected double Run(Array[] observations)
        {
            if (observations == null)
                throw new ArgumentNullException("observations");

            if (observations.Length == 0)
                throw new ArgumentException("Observation sequence vector must "+
                    "contain at least one observation sequence.", "observations");

            for (int i = 0; i < observations.Length; i++)
            {
                if (observations[i].Length == 0)
                {
                    throw new ArgumentException("The observation sequence at position "
                        + i + " is empty. Observation sequences must contain at least "
                        + " one observation.", "observations");
                }
            }

            LogWeights = new double[observations.Length];

            return run(observations);
        }

Same methods

BaseBaumWelchLearning::Run ( Array observations, double weights ) : double