-
Notifications
You must be signed in to change notification settings - Fork 115
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
distutils.errors.CompileError: command 'gcc' failed with exit status 1 #134
Comments
Hi @karenkane, What function did you run to get this error? Also, did you receive any other messages regarding the failure? |
Thanks for your reply! I tried the newly implemented 'bart_ewmv' model and got into trouble. Model name = bart_ewmv Details: of chains = 4of cores used = 1of MCMC samples (per chain) = 5000of burn-in samples = 1000of subjects = 105of (max) trials per subject = 145Error in open.connection(con, open = mode) : Timeout was reached: [github.com] Operation timed out after 10003 milliseconds with 0 out of 0 bytes received In addition: Warning message: In system(paste(CXX, ARGS), ignore.stdout = TRUE, ignore.stderr = TRUE) : 'C:/rtools40/usr/mingw_/bin/g++' not found ** Use random values as initial values ** SAMPLING FOR MODEL 'bart_ewmv' NOW (CHAIN 1). Chain 1: Rejecting initial value: Chain 1: Error evaluating the log probability at the initial value. Chain 1: Exception: bernoulli_logit_lpmf: Logit transformed probability parameter is nan, but must not be nan! (in 'model39a4241b148_bart_ewmv' at line 90) [1] "Error in sampler$call_sampler(args_list[[i]]) : Initialization failed." [1] "error occurred during calling the sampler; sampling not done" Stan model 'bart_ewmv' does not contain samples. Many thanks! Karen |
Karen, It seems the issue is not specific to ra_prospect('example', ncore = 1, nchain = 4, nwarmup = 100, niter = 200) If it returns the same error, it'd be better to re-install the Rtools on the machine. You can find further information from the following link: https://github.com/stan-dev/rstan/wiki/Configuring-C---Toolchain-for-Windows Jaeyeong |
Hi Jaeyeong, Thanks for your advice! The ra_prospect function can work with a few warnings. But I will try to re-install the Rtools. My problem is likely to be the same as a user's problem: Thanks again! |
@JaeyeongYang I install the hBayesDM follow the totorial and run the example code as follow:
and errors occur:
I'm confused about this, my conda env is brand new because I follow the tutorial and run the script
and the env packages are as follow:
Thank you, and I am happy to get your reply -best |
INFO:pystan:COMPILING THE C++ CODE FOR MODEL bart_ewmv_32f5883e88006cf8ab2634f30610150a NOW.
Traceback (most recent call last):
File "/usr/local/anaconda3/lib/python3.8/distutils/unixccompiler.py", line 117, in _compile
self.spawn(compiler_so + cc_args + [src, '-o', obj] +
File "/usr/local/anaconda3/lib/python3.8/distutils/ccompiler.py", line 910, in spawn
spawn(cmd, dry_run=self.dry_run)
File "/usr/local/anaconda3/lib/python3.8/distutils/spawn.py", line 36, in spawn
_spawn_posix(cmd, search_path, dry_run=dry_run)
File "/usr/local/anaconda3/lib/python3.8/distutils/spawn.py", line 157, in _spawn_posix
raise DistutilsExecError(
distutils.errors.DistutilsExecError: command 'gcc' failed with exit status 1
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "", line 1, in
File "/usr/local/anaconda3/lib/python3.8/site-packages/hbayesdm/models/_bart_ewmv.py", line 225, in bart_ewmv
return BartEwmv(
File "/usr/local/anaconda3/lib/python3.8/site-packages/hbayesdm/models/_bart_ewmv.py", line 15, in init
super().init(
File "/usr/local/anaconda3/lib/python3.8/site-packages/hbayesdm/base.py", line 63, in init
= self._run(**kwargs)
File "/usr/local/anaconda3/lib/python3.8/site-packages/hbayesdm/base.py", line 160, in _run
gen_init = self._prepare_gen_init_vb(data_dict, n_subj)
File "/usr/local/anaconda3/lib/python3.8/site-packages/hbayesdm/base.py", line 443, in _prepare_gen_init_vb
sm = self._designate_stan_model(model)
File "/usr/local/anaconda3/lib/python3.8/site-packages/hbayesdm/base.py", line 668, in _designate_stan_model
sm = StanModel(file=model_path, model_name=model,
File "/usr/local/anaconda3/lib/python3.8/site-packages/pystan/model.py", line 378, in init
build_extension.run()
File "/usr/local/anaconda3/lib/python3.8/distutils/command/build_ext.py", line 340, in run
self.build_extensions()
File "/usr/local/anaconda3/lib/python3.8/distutils/command/build_ext.py", line 449, in build_extensions
self._build_extensions_serial()
File "/usr/local/anaconda3/lib/python3.8/distutils/command/build_ext.py", line 474, in _build_extensions_serial
self.build_extension(ext)
File "/usr/local/anaconda3/lib/python3.8/distutils/command/build_ext.py", line 528, in build_extension
objects = self.compiler.compile(sources,
File "/usr/local/anaconda3/lib/python3.8/distutils/ccompiler.py", line 574, in compile
self._compile(obj, src, ext, cc_args, extra_postargs, pp_opts)
File "/usr/local/anaconda3/lib/python3.8/distutils/unixccompiler.py", line 120, in _compile
raise CompileError(msg)
distutils.errors.CompileError: command 'gcc' failed with exit status 1
The text was updated successfully, but these errors were encountered: