Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Markovian distribution using Zygote #21

Open
mohamed82008 opened this issue Jan 11, 2020 · 0 comments
Open

Markovian distribution using Zygote #21

mohamed82008 opened this issue Jan 11, 2020 · 0 comments

Comments

@mohamed82008
Copy link
Member

Currently, time-series models are very slow in Turing compared to Stan mainly because of the dynamic dispatch of Tracker.jl. Loops are hard to avoid in such models and loops currently make Tracker AD super slow. Last I checked, Zygote was also not fully ready for action to be adopted in Turing.jl. However, if we can define a Markovian distribution with a recursive function that given the previous state returns a distribution for the next state, and then make Zygote differentiate it successfully, we can then use Zygote to define a Tracker primitive for the logpdf function of this distribution much like how we handle MvNormal. This should enable fast reverse-mode AD of time series models in Turing.jl. Not sure how feasible this is, but might be worth investigating.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant