Closed xidulu closed 1 year ago
Yes. You are right. Im not very good with pymc3. If you can add a PR that would be great.
I think you should use exp since that is what stan is doing and then we can check that we get the same log density for models both in pymc3 and stan.
@MansMeg Happy to open a PR to fix it, but I am not sure how to check the equivalence of log_density, could you provide some instruction on it?
Thanks
Are you running PyStan? Then you could just input some random parameter values for both the stan and the pymc3 model. They should return exactly the same value of the log density. See here on the log_prob in rstan. https://mc-stan.org/rstan/reference/stanfit-method-logprob.html
@MansMeg Thanks! I will have a look
Hi!
I close this issue for now. Just reopen it if you have further questions.
tau
, the scale parameter should lie on the positive real value space therefore it should be HalfCauchy or be transformed through exponential function?https://github.com/stan-dev/posteriordb/blob/master/posterior_database/models/pymc3/eight_schools_noncentered.py#L14