-
-
Notifications
You must be signed in to change notification settings - Fork 187
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
[WIP] Laplace Approximation #2594
Conversation
…ev/math into try-laplace_approximation
…4.1 (tags/RELEASE_600/final)
@@ -0,0 +1,441 @@ | |||
#ifndef STAN_MATH_LAPLACE_LAPLACE_LIKELIHOOD_HPP |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this file just be deleted?
const Eigen::Matrix<T_theta, Eigen::Dynamic, 1>& theta, | ||
const Eigen::Matrix<T_eta, Eigen::Dynamic, 1>& eta, | ||
Eigen::Matrix<return_type_t<T_theta, T_eta>, Eigen::Dynamic, 1>& gradient, | ||
Eigen::Matrix<return_type_t<T_theta, T_eta>, Eigen::Dynamic, 1>& hessian, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All the other diff
methods expect a sparse matrix as the hessian, should this as well? laplace_marginal_density
currently passes a sparse matrix as the hessian
…4.1 (tags/RELEASE_600/final)
var target | ||
= laplace_marginal_density(diff_functor, K, phi_v, eta_v, x, delta, | ||
delta_int, theta_0); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This test is failing because neg_binom
does not have a defined compute_s2
method which is needed in the vari constructor. What is compute_s2
doing? Is neg_binom
deprecated so we should just remove these tests?
Also should we be using the https://eigen.tuxfamily.org/dox/unsupported/classEigen_1_1BlockSparseMatrix.html |
Changed status to draft; looks like a bunch of work left to do here. |
Closing this. @charlesm93 https://github.com/stan-dev/math/tree/experimental/laplace is the most recent version right? |
Summary
This is a very WIP PR, mostly for @charlesm93 and I to debug some things
Tests
Side Effects
Release notes
Checklist
Math issue #(issue number)
Copyright holder: Charles Margossian and Steve Bronder
The copyright holder is typically you or your assignee, such as a university or company. By submitting this pull request, the copyright holder is agreeing to the license the submitted work under the following licenses:
- Code: BSD 3-clause (https://opensource.org/licenses/BSD-3-Clause)
- Documentation: CC-BY 4.0 (https://creativecommons.org/licenses/by/4.0/)
the basic tests are passing
./runTests.py test/unit
)make test-headers
)make test-math-dependencies
)make doxygen
)make cpplint
)the code is written in idiomatic C++ and changes are documented in the doxygen
the new changes are tested