-
Notifications
You must be signed in to change notification settings - Fork 32
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
Implement vb and adapt interface #74
Conversation
I'm starting a review on this one but it seems to be a lot of tickets joined into one PR. @seabbs please can you try and keep them to separate branches for future changes? 48 files, +1018 lines, -101,232 lines is not a good sign for me being able to hold it all in my head (even if -100,001 is one file being removed) ;) edit - I can see they may be intertwined so hard to split |
Unfortunately, supporting VB required a large-scale interface change so this is a minimal PR. |
Any issues with this @joeHickson or happy for me to merge in? |
still reviewing! |
(and yes, I have left comments but because it's mid-review I don't think it's exposed them to you yet) |
epinow: Reorder the arguments passed to estimate_infections
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.
We should have a chat about code styling standards on the call later - there's a few bits in here that change from one style to another with regards line breaks and it slows down the review a bit.
one or two minor bits and a couple of larger ones, notably:
The stan_args generation method is a bit wierd in the way some properties are native arguments and others are a list that is passed in (as stan_args), and then the calling places treat both the original stub list and the returning object as stan_args. I can see this is to do with how you pass the list of user defined options in to where it's generated. I have suggested some R6 objects but there are other ways around this one (including other structures of R6 objects), but if the current structure is kept some renaming should be done to clarify when the list is a stan_args stub and when it's a full stan_args list.
The use of magic strings is something that I spotted whilst reviewing - this task adds a few more. Suggestions as to how can be found on incubation-period.R but again there are multiple ways to crack this nut.
Thanks for the review @joeHickson. Addressed the minor issue with Merging this now as I think the main features are in place and will bring some solid user benefits. |
Implement vb and adapt interface
This PR combines updating the package interface (based on #73 and feedback from @pearsonca) with added support for variational inference (#72). It contains breaking changes that will impact all downstream users but substantially simplify the end-user experience whilst adding the ability for future extensions. See the updated readme and examples for new implementation details.
Changes
stan_args
with defaults fromcreate_stan_args
stan_args
as undocumented features (i.estuck_chains
).Relevant to: @kathsherratt @pearsonca @joeHickson @jhellewell14