-
Notifications
You must be signed in to change notification settings - Fork 4
Added Bayes benchmark script #105
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
Conversation
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.
Alongside these comments, I'm having trouble running both the script and jupyter notebook. Is this due to the backgrounds bug, or is there something else?
@DrPaulSharp they both run fine for me, but I may have something weird going on with my binary. what kind of error were you getting? |
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 looks good now and I have it working, it just needs some updates. Please confirm everything works as expected when they're done.
@DrPaulSharp can confirm everything works as expected now |
This PR fixes part of #92 by adding the Bayes benchmark script, which calculates the posterior distributions for a two- and three-dimensional example 'from scratch' and compares them to the distributions generated by the nested sampler and DREAM.
The Python script is mostly similar in workflow to the MATLAB one, but the direct calculation of the posterior is vectorised and the module/function docstrings go into a little more detail on what is actually being done, for users who may not be familiar with the basics of Bayesian reflectivity analysis.
This PR also fixes a minor issue with the plotting library - the axes on the contour plots were the wrong way around (but then were flipped to be correct on corner plots)!