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

Better handling of adaptation and algorithm parameters #24

Merged
merged 2 commits into from
Aug 11, 2017

Conversation

LeahPrice
Copy link
Collaborator

Following on from our discussion in #23, I'm now passing the algorithm parameters to all of the necessary functions.

The first commit separates the algorithm parameters and adaptation object. The algorithm parameters are passed to the adaptation functions and accessed elsewhere through Sampler->GetAlgParams(). The second commit goes further to pass the algorithm parameters to the moveset functions as well.

Sorry about all of the white space changes hiking up the addition/deletion numbers. I'm not even sure how I would have gone about changing a whole section of indentation like that, but I had the ignore white space option in Gitkraken turned on so I didn't notice (I've turn it off now).

Taking the additional parameters out of the adaptation object and making them a member of sampler.

Referring to the Sampler object directly to get the algorithm parameters in the examples.
Copy link
Collaborator

@adamjohansen adamjohansen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This all looks good to me and seems to resolve a problem I was having elsewhere, so thank you...

There should be an entry in NEWS for a change of this magnitude, though...

(If you find yourself needing to make a lot of changes to whitespace it can be convenient to commit those separately so that it's apparent that none of the changes do anything of substance...)

@eddelbuettel
Copy link
Collaborator

Second Adam's comment re NEWS, lovely that you keep ChangeLog current with good detail, a higher level change entry for NEWS.Rd is always good too.

@eddelbuettel eddelbuettel merged commit fb1b63c into rcppsmc:master Aug 11, 2017
@LeahPrice
Copy link
Collaborator Author

Okay, thanks. I had been writing the entries after the pull requests so I can reference the pull request, but I guess I know what number it will be beforehand anyway. I'll update that in the next pull request.

@LeahPrice LeahPrice deleted the PassingParameters branch August 12, 2017 00:47
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

Successfully merging this pull request may close these issues.

3 participants