donaldRwilliams / chkptstanr

Checkpoint Stan R
https://donaldrwilliams.github.io/chkptstanr/
Other
9 stars 5 forks source link

chkpt_brms does not work with custom families, data2, etc #15

Open venpopov opened 8 months ago

venpopov commented 8 months ago

When you run chkpt_brms with custom_families, data2 argument or some others, the model compiles and samples, but then fails. For example see here

The same happens if using a custom family, in which case you get an error that some parameters are "not valid distributional parameters".

This is all because the ... arguments passed to chkpt_brms by the user are not passed to make_brmsfit, so the conversion between the cmdstanr results to brmsfit cannot work.

I fixed this in a general way and will submit a PR soon. Now chkpt_brms should work with any brms model