Viterbi training or Baum-Welch algorithm to estimate the transition and emission probabilities?
Asked Answered
W

3

10

I'm trying to find the most probable path (i.e. a sequence of states) on an HMM using the Viterbi algorithm. However, I don't know the transition and emission matrices, which I need to estimate from the observations (data).

To estimate these matrices, which algorithm should I use: the Baum-Welch or the Viterbi training algorithm? Why?

In case I should use the Viterbi training algorithm, can anyone provide me a good pseudocode (it's not easy to find)?

Weeny answered 13/11, 2012 at 12:35 Comment(0)
S
14

Given enough resources, you should probably use the Baum-Welch (forward-backward) algorithm over the Viterbi training algorithm (a.k.a. segmental k-means algorithm), which is an alternative parameter estimation process that sacrifices some of Baum-Welch's generality for computational efficiency. In general, the Baum-Welch algorithm will give parameters that lead to better performance, although there are cases where this is not the case. Here is a nice comparative study.

Furthermore, note that you should use the Baum-Welch algorithm to estimate the parameters of the model. This sets the emission probability and transmission probabilities using something similar to the EM algorithm. After you have trained the HMM, you would then use the Viterbi decoding algorithm to compute the most likely sequence of states which could have generated your observations.


Reference-wise I would recommend Speech and Language Processing, Artificial Intelligence a Modern Approach or this paper

Surfing answered 15/11, 2012 at 14:54 Comment(0)
C
0

From http://nlp.stanford.edu/courses/lsa352/lsa352.lec7.6up.pdf:

Viterbi Training is, compared to Baum-Welch:

  • Much faster
  • But doesn’t work quite as well
  • But the tradeoff is often worth it.

Some comparative studies:

The same question was asked on Statistics Stack Exchange: Differences between Baum-Welch and Viterbi training.

Cottager answered 1/1, 2017 at 3:52 Comment(0)
V
-1

you have to go through baum welch algorithm to find out hidden Markov model parameters. baum welch uses forward and backward algorithm to find out hmm parameter.

I have one link for baum welch algorithm code in python just check it: https://jyyuan.wordpress.com/2014/01/28/baum-welch-algorithm-finding-parameters-for-our-hmm/

Veriee answered 1/6, 2016 at 11:18 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.