RSS
热门关键字:  数据挖掘  人工智能  数据仓库  搜索引擎  数据挖掘导论

前向算法使用实例(Forward Algorithm)

来源: 作者:unkonwn 时间:2004-11-29 点击:

Example

Page 3 of this section contains an interactive example of the forward algorithm.

To use the example follow these steps :

数据挖掘研究院

  1. Enter a number of valid observed states in the input field.
  2. Press ′Set′ to initialise the matrix.
  3. Use either ′Run′ or ′Step′ to make the calculations.
    • ′Run′ will calculate the a′s for each and every node and return the probability of the HMM.
    • ′Step′ will calculate the a value for the next node only. Its value is displayed in the output window.

When you have finished with the current settings you may press ′Set′ to reinitialise with the current settings, or you may enter a new set of observed states, followed by ′Set′.

数据挖掘研究院

States may be entered in either or a combination of the following :

数据挖掘研究院

Dry, Damp, Soggy

or 数据挖掘研究院

Dry Damp Soggy

i.e. valid separators are comma and space. If any invalid state or separator is used then the states remain unchanged from their previous settings 数据挖掘研究院

  数据挖掘实验室

See next page for the example.

Description of model used in the example

Hidden States
(weather)
Sunny
Cloudy
Rainy
Observed States
(seaweed)
Dry
Dryish
Damp
Soggy
Initial State Probabilities
(P Vector)
Sunny 0.63
Cloudy 0.17
Rainy 0.20

Description of model used in the example

State transition matrix (′A′ matrix)
weather

数据挖掘实验室


yesterday
weather today
  Sunny Cloudy Rainy
Sunny 0.500 0.250 0.250
Cloudy 0.375 0.125 0.375
Rainy 0.125 0.675 0.375
Confusion matrix (′B′ matrix)
hidden
states
observed states
  Dry Dryish Damp Soggy
Sunny 0.60 0.20 0.15 0.05
Cloudy 0.25 0.25 0.25 0.25
Rainy 0.05 0.10 0.35 0.50

Summary

We use the forward algorithm to find the probability of an observed sequence given a HMM. It exploits recursion in the calculations to avoid the necessity for exhaustive calculation of all paths through the execution trellis.

Given this algorithm, it is straightforward to determine which of a number of HMMs best describes a given observation sequence - the forward algorithm is evaluated for each, and that giving the highest probability selected.

最新评论共有 0 位网友发表了评论
发表评论
评论内容:不能超过250字,需审核,请自觉遵守互联网相关政策法规。
匿名?