-
Notifications
You must be signed in to change notification settings - Fork 5
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
Metropolis-Hastings Monte Carlo: Improve move_ratio kwarg #321
Comments
I forgot to mention |
Yeah I am in favor of attempting to improve the API. Whenever I used this I would always have to check which way round it was supposed to be. I wouldn't worry too much about breaking other people's code as I doubt we have many people counting on this behavior. Just make sure we effectively communicate the change. You could consider adding an option so that only a single move is attempted at a time, that would be a good option for most cases. |
- Update ThermalMonteCarlo.jl with new keywords movement_ratio and stop_ratio, where movement_ratio=1-stop_ratio - Add warning for deprecated kwargs. - Update documentation with information about new keywords
I've done some limited testing on 45e47ea. Both the test suite and the system I'm modelling behave properly and sampling stays stuck on the same structures less for my larger system. |
- Update ThermalMonteCarlo.jl with new keywords movement_ratio and stop_ratio, where movement_ratio=1-stop_ratio - Add warning for deprecated kwargs. - Update documentation with information about new keywords
In general, the keywords should be as descriptive as possible. |
Docs are updated to include information about the changes: https://nqcd.github.io/NQCDynamics.jl/previews/PR325/initialconditions/metropolishastings/ |
1. AdvancedMH or one of its dependencies may have updated a keyword from "initial_config" to "initial_params". This caused NQCD to not deliver initial positions to the sampling chain correctly, leading to weird results for systems not centred around 0. 2. Updated new keywords `movement_ratio` and `stop_ratio`, where `movement_ratio=1-stop_ratio` as the old `move_ratio` was confusing. Warning for deprecated kwargs was added and documentation updated with information about new keywords * Drop compat for AdvancedMH.jl<0.8 for #320,#321 * Version bump for #325
I would suggest two (breaking) changes to
run_advancedmh_sampling
(Code):move_ratio
for its inverse: To me, it seems more logical for a move ratio of 0 to prevent the entire system from moving, while 1 causes the entire system to move. Doing it the other way round seems weird to me. Possibly we could split frommove_ratio
intostop_ratio
andmovement_ratio
, wherestop_ratio=1-movement_ratio
and deprecatemove_ratio
to avoid breaking stuff.The text was updated successfully, but these errors were encountered: