Add option for linking and executing models through R/Rcpp to avoid admin issues with executables
Nobody has claimed this yet.
- Dominant language
- R
- Stars
- 160
- Forks
- 69
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 15
Description
As discussed in #815 and many other issues and forum posts, users in organisations aren't able to use cmdstanr (or at least not without some difficulty) due to organisational restrictions in running arbitrary executables.
To avoid this, we could add an option to instead execute the model via Rcpp - by linking the compiled object file as an R-compatible DLL via R CMD SHLIB. This is essentially how rstan models are executed.
Much of the minutiae in platform-specific handling for this will be covered in #894, the main complexity will come from plumbing it into the $sample()/$optimize()/etc methods
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Review the discussions in #815 and #894 first to understand the proposed R/Rcpp execution path and platform-specific handling. Then trace how $sample(), $optimize(), and related methods currently execute models. Done means an option can execute models through an R-compatible DLL without requiring users to run arbitrary executables.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- r
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100