You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As currently written, when stan::io::stan_csv_reader encounters a file with saved warmup draws,
the parser will return both warmup and sample draws, but no adaptation information.
Instead, the reader should check the parsed metatdata to determine whether or not there are saved warmup draws.
If there are, these can be discarded, as the consumer of the resulting stan_csv object - stan::mcmc::chains doesn't need them.
Description:
The parser expects to find the following element in the following order:
metadata
header
adaptation
samples, followed by timing.
Function read_adaptation is called after the header line has been consumed. If the following line is not a comment block, it returns. An error is written to the supplied stream out and the parser then calls read_samples. Read samples then reads both the warmup and post-warmup draws.
The returned object contains warmup and post-warmup draws, but no information about step-size or metric.
Reproducible Steps:
Get outputs from 2 runs of a Stan model, w/ and w/out save_wamup=true.
Parse both with stan_csv_reader, examine the returned stan_csv object, e.g.:
Summary:
As currently written, when
stan::io::stan_csv_reader
encounters a file with saved warmup draws,the parser will return both warmup and sample draws, but no adaptation information.
Instead, the reader should check the parsed metatdata to determine whether or not there are saved warmup draws.
If there are, these can be discarded, as the consumer of the resulting
stan_csv
object -stan::mcmc::chains
doesn't need them.Description:
The parser expects to find the following element in the following order:
Function
read_adaptation
is called after the header line has been consumed. If the following line is not a comment block, it returns. An error is written to the supplied streamout
and the parser then callsread_samples
. Read samples then reads both the warmup and post-warmup draws.The returned object contains warmup and post-warmup draws, but no information about step-size or metric.
Reproducible Steps:
save_wamup=true
.stan_csv_reader
, examine the returnedstan_csv
object, e.g.:Current Output:
bernoulli_default 1000 sample size 1000 step size 0.932037
bernoulli_warmup 1000 sample size 2000 step size 0
Expected Output:
Both should have sample size 1000, and step size close to 0.93.
Additional Information:
Provide any additional information here.
Current Version:
v2.35.0
The text was updated successfully, but these errors were encountered: