Closed snailittle closed 2 years ago
First, the general instruction for windows users can be found here https://mc-stan.org/docs/2_27/cmdstan-guide/cmdstan-installation.html#windows-make.
On your account, you might want to check the path C:\Users\zhup3107\DOCUME1\rtools40\rtools40\mingw64\bin
and C:\Users\zhup3107\DOCUME1\rtools40\rtools40\usr\bin
for mingw32-make
. If it's located, you can add these paths to your environment variables.
I can't seem to find mingw32-make in these folders. It seems the admin account is a separate account on the company computer. and whatever installed there may not translate into the user account.
When a user has only limited access to the machine it's not easy to determine if Torsten has installation issue or something went wrong during the process. Any chance you can try it on a PC with full access?
I was able to get past that step by copying a working rtoos40 from another computer. but I do run into issue when compiling models. Not sure what it means by " can't find files for the given patterns".
model <- cmdstan_model(stanfile) Compiling Stan program... INFO: Could not find files for the given pattern(s). % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0 curl: (60) SSL certificate problem: unable to get local issuer certificate More details here: https://curl.haxx.se/docs/sslcerts.html
curl failed to verify the legitimacy of the server and therefore could not establish a secure connection to it. To learn more about this situation and how to fix it, please visit the web page mentioned above. mingw32-make.exe: *** [make/stanc:70: bin/stanc.exe] Error 60 Error: An error occured during compilation! See the message above for more information.
This indicates an issue of out-of-date certificate. It's better to enlist help from IT. On the other hand, since the issue happened when downloading stanc binary, you can try to do it manually. For example, for Torsten, you can download the windows binary at
https://github.com/metrumresearchgroup/stanc3/releases/download/torsten_v0.89rc2/windows-stanc
and copy the downloaded to Torsten/cmdstan/bin/stanc.exe
, then retry building the model.
Hi Yi. Many thanks for the instruction. I will try it Per the instruction for installation of cmdstanr and CmdStan, (https://mc-stan.org/cmdstanr/articles/cmdstanr.html) I think for Torsten we don't need to install CmdStan because the folder is already in the torsten zip files. I can just set the path and start using it. am I correct? or do we need to follow the instruction in the link to install cmdstan into another location and not use the same named folder torsten zip files folder? or should I install cmdstan again into the torsten cmdstan folder? Many thanks. Penny On Friday, September 10, 2021, 11:19:40 PM EDT, Yi Zhang @.***> wrote:
This indicates an issue of out-of-date certificate. It's better to enlist help from IT. On the other hand, since the issue happened when downloading stanc binary, you can try to do it manually. For example, for Torsten, you can download the windows binary at
https://github.com/metrumresearchgroup/stanc3/releases/download/torsten_v0.89rc2/windows-stanc
and copy the downloaded to Torsten/cmdstan/bin/stanc.exe, then retry building the model.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android.
Many thanks for the instruction. I will try it
Per the instruction for installation of cmdstanr and CmdStan, (https://mc-stan.org/cmdstanr/articles/cmdstanr.html) I think for Torsten we don't need to install CmdStan because the folder is already in the torsten zip files. I can just set the path and start using it. am I correct? or do we need to follow the instruction in the link to install cmdstan into another location and not use the same named folder torsten zip files folder? or should I install cmdstan again into the torsten cmdstan folder?
Many thanks.
tried to download the file via link https://github.com/metrumresearchgroup/stanc3/releases/download/torsten_v0.89rc2/windows-stanc and saved the file into torsten/cmdstan/bin folder and renamed to stanc.exe.
Tried to compile the model and still get an error. Maybe I did something wrong?
library(cmdstanr) setwd("C:/Users/zhup3107/Documents/Ranalysis/") set_cmdstan_path("C:/Users/zhup3107/Documents/Ranalysis/Torsten/cmdstan") file.dir <- file.path("Torsten", "example-models", "pk2cpt") stanfile <- file.path(file.dir, "pk2cpt.stan")
model <- cmdstan_model(stanfile) Compiling Stan program... Error: An error occured during compilation! See the message above for more information.
Error: An error occured during compilation! See the message above for more information.
I don't see any error message. I wonder if there's something missing here.
To check if the downloaded binary works, you can do
system("C:/Users/zhup3107/Documents/Ranalysis/Torsten/cmdstan/bin/stanc.exe C:/Users/zhup3107/Documents/Ranalysis/Torsten/example-models/pk2cpt/pk2cpt.stan")
This should generate pk2cpt.hpp
in the project folder.
I was able to download stanc.exe and verify that the above command worked and generated the hpp file. Now trying to run Torsten and it seems working all right. Many thanks! You are a life saver!
My Rtools40 is missing mingw32-make. I tried to run the following check_cmdstan commands and it didn't work.
I realized it may be due to the computer being company restricted. Therefore I called IT and asked them to sign in as admin. As R-studio was installed under my account and wouldn't run in admin account, I used Rtools bash to run the following command to install mingw32-make
pacman -Syu mingw-w64-X86_64-make.
It seems to be installing all right, all process reporting 100% installation. However after IT logged off, I came back to my own account, the same issue persisted. and I couldn't find where the ingw32-make was installed.
I tried the following command which showed that it still can't find mingw32-make. Now what should I do? Should I ask IT to log in as admin, reinstall Rtools40 and Rstudio as admin then set up the toolchain using "check_cmdstan_toolchain(fix = TRUE)" in R?
Is there a quick fix to find out why the installation for mingw32-make under admin didn't work when I logged back into my account? Many thanks.