Error in unserialize(socklist[[n]]) : error reading from connection (ts_par4)
Hello, Thank you for making the modelling code for the two-step task available.
We are currently trying to implement the hBayesDM hybrid model (ts_par4) and we keep running into a problem. We are using a MacBook Pro 8 GB memory, and have installed the toolbox and associated packages according to the description.
We are using the following command: outputALL_out <- ts_par4( data = dataALL_out_corr, niter = 2000, nwarmup = 1000, nchain = 4, ncore = 4)
The first chain seems to run fine, but we get the following error message when the second is being started: Error in unserialize(socklist[[n]]) : error reading from connection
When changing the number of chains to 1 the R session crashes.
Would you be able to advise us on how to proceed or what we are doing incorrectly? Thank you! Franziska
Thanks for reporting the issue, @fknolle11, and apologies for the delayed response.
Seems that there exists an issue with using detailed configurations with rstan, which leads to this error (see more on this link: https://discourse.mc-stan.org/t/r-session-aborts-when-using-the-control-argument/23508).
I made a temporary fix on the development version in the Github, so before we release a new version of hBayesDM, you can try it by yourself as below:
# `devtools` is required to install hBayesDM from GitHub
if (!require(devtools)) install.packages("devtools")
devtools::install_github("CCS-Lab/hBayesDM", ref="develop", subdir="R")
Had the same issue with 4 chains, dd_hyperbolic