Hidden Markov Model
Explain
You have three observable states {sleep, eat, poop} of your dog.
From the past observations, you want to know the current state of your dog, {sick, healthy}
Since you don't know the current state, its hidden, therefore, hidden state.
To infer the hidden state, we need to know the following parameters
1) Initial probability for the hidden
2) Transition probability for the hidden
3) Emission probability, which is the probability of the observation given the hidden. For examples,
|
Eat |
Sleep |
Poop |
Sick |
0.2 |
0.6 |
0.2 |
Healty |
0.4 |
0.1 |
0.5 |
The problem is..How to estimate 1) ,2), and 3?
1) and 2) can be obtained by the dynamic programming, 3) can be obtained by the EM-algorithm.
Visit,
http://scikit-learn.sourceforge.net/stable/modules/hmm.html
http://www.blackarbs.com/blog/introduction-hidden-markov-models-python-networkx-sklearn/2/9/2017
Library installation (python 2.7)
1. install numpy related libraries
2. install scikit-learn
3. install hmmlearn