We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
initval
I found some issues with the recent initval changes in #4729, as it doesn't respect the parents initvals.
This snippet often leads to a ValueError:
ValueError
with pm.Model() as model: mu = pm.Normal('mu', initval=100) alpha = pm.HalfNormal('alpha', initval=100, transform=None) value = pm.NegativeBinomial('value', mu=mu, alpha=alpha) model.initial_values # {mu: array(100., dtype=float32), # alpha: array(100., dtype=float32), # value: array(1)}
When it doesn't fail, initval is still far from the expected ~ 100:
pm.NegativeBinomial.dist(mu=100, alpha=100).eval() # array(98)
Originally posted by @ricardoV94 in #4734 (comment)
The text was updated successfully, but these errors were encountered:
Also a model where pm.Flat is used as input will now raise an error unless an initval is set for those variables:
pm.Flat
with pm.Model() as m: x = pm.Flat('x') y = pm.Normal('y', x, 1)
NotImplementedError: Cannot sample from flat variable
Sorry, something went wrong.
givens
Model.set_initval
closed by #4738
brandonwillard
Successfully merging a pull request may close this issue.
I found some issues with the recent
initval
changes in #4729, as it doesn't respect the parents initvals.This snippet often leads to a
ValueError
:When it doesn't fail, initval is still far from the expected ~ 100:
Originally posted by @ricardoV94 in #4734 (comment)
The text was updated successfully, but these errors were encountered: