I use brms to generate stan code and stan data on my local machine. I then transfer both to an ubuntu virtual machine (VM) and run the models using cmdstanr. We are struggling to install brms on the VM, which is why we used this option. This works really well for model results and diagnostics, but makes it difficult to calculate loo.
Is there an option somewhere in brms to add calculation of the log-likelihood to the generated quantities block in the stan model that brms produces? I couldn’t see this anywhere in the options. Presumably there must be brms code which generates the stan log-likelihood code for a given model, since there is the brms::logLik.brmsfit function?
I appreciate that this might be a fairly unusual case so this might not be something anyone else wants to spend time on.