Within-chain parallelization in Ubuntu (WSL) not working.
Nobody has claimed this yet.
- Dominant language
- R
- Stars
- 1.1k
- Forks
- 266
- Avg merge
- 2h 56m
- Merged PRs (30d)
- 1
Description
I have tried to fit a model with Within-chain parallelization using Ubuntu (through WSL) and am getting an error. The model normally works if I comment on the 'threads' argument. The model also works normally on Windows 10 (normally). Here is the model:
ccCicv <-
brm(
data = py$dfClean,
family = student,
cc ~ 1,
prior = c(
prior(normal(mean_y, sd_y * 5), class = Intercept),
prior(cauchy(0, sd_y), class = sigma),
prior(exponential(one_over_twentynine), class = nu)
),
stanvars = ccVars,
iter = 200000,
warmup = 4000,
chains = 4,
cores = 4,
seed = 123456,
thin = 100,
#control = list(adapt_delta = .90, max_treedepth = 15),
backend = "cmdstanr",
threads = threading(6)
)
Here is the error:
Error: Syntax error found! See the message above for more information.
7.
stop("Syntax error found! See the message above for more information.",
call. = FALSE)
6.
cmdstan_mod$format(canonicalize = list("deprecations", "braces",
"parentheses"), overwrite_file = overwrite_file, backup = FALSE)
5.
withVisible(...elt(i))
4.
utils::capture.output(cmdstan_mod$format(canonicalize = list("deprecations",
"braces", "parentheses"), overwrite_file = overwrite_file,
backup = FALSE))
3.
.canonicalize_stan_model(tmp_file, overwrite_file = FALSE)
2.
.make_stancode(bterms, data = data, prior = prior, stanvars = stanvars,
save_model = save_model, backend = backend, threads = threads,
opencl = opencl, normalize = normalize)
1.
brm(data = py$dfClean, family = student, cc ~ 1, prior = c(prior(normal(mean_y,
sd_y * 5), class = Intercept), prior(cauchy(0, sd_y), class = sigma),
prior(exponential(one_over_twentynine), class = nu)), stanvars = ccVars,
iter = 200000, warmup = 4000, chains = 4, seed = 123456, ...
BRMS version: 2.20.4
CMDSTANR version: 0.7.1
rstan version: 2.32.6
stanheaders version: 2.32.6
What I just did:
Updated the Linux;
Updated all packages from CRAN;
Installed RccpParallel from git-hub (current version: 5.1.7-9001);
Re-compiled the constant locally.
Contributor guide
No contributing guide indexed for this repository
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
The payload names no repository file or test. Start by reproducing the supplied brm call with backend="cmdstanr" and threads=threading(6) under Ubuntu/WSL using the listed versions, then inspect the full formatter syntax error; done would be a confirmed cause and a regression test or documented fix for within-chain parallelization.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- r, ubuntu
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100