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

WSL - Run cmdstan and models under WSL filesystem #696

Merged
merged 53 commits into from
Oct 29, 2022
Merged

WSL - Run cmdstan and models under WSL filesystem #696

merged 53 commits into from
Oct 29, 2022

Conversation

andrjohns
Copy link
Collaborator

Submission Checklist

  • Run unit tests
  • Declare copyright holder and agree to license (see below)

Summary

This PR refactors the WSL functionality introduced in #677 so that cmdstan is built and stored within the WSL installation, and the model execution occurs exclusively within the WSL installation as well.

This is possible due to functionality for accessing the WSL filesystem from Windows via the //wsl$/ network path. This allows for cmdstanr to execute models through WSL, and then access the generated .csv files from the windows session. This is also reflected in the cmdstan path, for example:

> library(cmdstanr)
This is cmdstanr version 0.5.3
- CmdStanR documentation and vignettes: mc-stan.org/cmdstanr
- CmdStan path: //wsl$/Ubuntu-22.04/home/andrew/.cmdstan/cmdstan-2.30.1
- CmdStan version: 2.30.1

My anecdotal experience so far is a noticeable decrease in both cmdstan installation time, as well as model compilation time

Copyright and Licensing

Please list the copyright holder for the work you are submitting
(this will be you or your assignee, such as a university or company):
Andrew Johnson

By submitting this pull request, the copyright holder is agreeing to
license the submitted work under the following licenses:

@codecov-commenter
Copy link

codecov-commenter commented Aug 26, 2022

Codecov Report

Merging #696 (71c0ea7) into master (53084da) will decrease coverage by 2.11%.
The diff coverage is 35.52%.

@@            Coverage Diff             @@
##           master     #696      +/-   ##
==========================================
- Coverage   90.56%   88.44%   -2.12%     
==========================================
  Files          12       12              
  Lines        3890     4017     +127     
==========================================
+ Hits         3523     3553      +30     
- Misses        367      464      +97     
Impacted Files Coverage Δ
R/run.R 94.54% <16.66%> (-0.74%) ⬇️
R/utils.R 73.52% <18.33%> (-13.35%) ⬇️
R/model.R 90.62% <43.75%> (-1.12%) ⬇️
R/fit.R 97.43% <50.00%> (-0.75%) ⬇️
R/install.R 62.01% <50.00%> (-0.93%) ⬇️
R/path.R 76.82% <59.45%> (+5.77%) ⬆️
R/args.R 97.92% <69.23%> (-0.75%) ⬇️
R/csv.R 97.66% <100.00%> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@andrjohns
Copy link
Collaborator Author

Closing to run workflows in my own fork

@andrjohns andrjohns closed this Oct 24, 2022
@andrjohns andrjohns reopened this Oct 25, 2022
@rok-cesnovar
Copy link
Member

Thanks Andrew! Will do another release this week, hopefully with some other minor features.

@rok-cesnovar rok-cesnovar merged commit f8f6321 into stan-dev:master Oct 29, 2022
@andrjohns
Copy link
Collaborator Author

Great! I've just got one more PR to fix the WSL CI tests hanging, will have that in a couple days

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