stan
stan copied to clipboard
add logic to standalone gqs to handle samples where parameter is a zero-length container
Summary:
see discussion https://discourse.mc-stan.org/t/generated-quantities-for-0-dim-vectors-matrices/11514/8 and here https://github.com/stan-dev/rstan/issues/708
Description:
before calling transform_inits, create var_context where all params are present with default value 0 - because transform_inits tries to unconstrained all parameters.
Reproducible Steps:
Please report steps to reproduce the issue. If it's not possible to reproduce, please include a description of how you discovered the issue.
If you have a reproducible example, please include it.
Current Output:
The current output. Knowing what is the current behavior is useful.
Expected Output:
Describe what you expect the output to be. Knowing the correct behavior is also very useful.
Additional Information:
Provide any additional information here.
Current Version:
v2.21.0