Allowing changing transition matrix for hmm suites
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 839
- Forks
- 220
- Avg merge
- 2d 4h
- Merged PRs (30d)
- 14
Description
Description
Currently we only allow users to pass a fix transition matrix when calling any one of three functions for Hidden Markov Models:
hmm_marginalhmm_hidden_state_probhmm_latent_rng
In some models, the user needs to pass a transition matrix that changes over (discrete) time. To accommodate this, we need to revise the code so that it can handle an array of transition matrices, where the number of matrices is K (the number of unobserved discrete variables).
Example
See this discussion on the Stan forum.
Expected Output
Overload all signatures for hmm functions so that they can accept an array of transition matrices, rather than a single transition matrix.
Current Version:
v4.3.0
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the implementations and overloads for hmm_marginal, hmm_hidden_state_prob, and hmm_latent_rng, then trace how each currently accepts a fixed transition matrix. Update the signatures and behavior to accept K time-varying transition matrices, and verify that all three HMM functions support the expected array form.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- data
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100