Skip to content
New issue

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

Scan logprob fails when not all RVs are valued #135

Open
Tracked by #229
ricardoV94 opened this issue Apr 12, 2022 · 0 comments
Open
Tracked by #229

Scan logprob fails when not all RVs are valued #135

ricardoV94 opened this issue Apr 12, 2022 · 0 comments
Labels
bug Something isn't working op-probability Involves the implementation of log-probabilities for Aesara `Op`s scan

Comments

@ricardoV94
Copy link
Contributor

import aesara
import aesara.tensor as at
import aeppl

# init = at.random.beta(1, 1)
(x, y), _ = aesara.scan(
    fn=(lambda x, y: (at.random.normal(), at.random.normal())),
    outputs_info=[at.zeros(()), at.zeros(())],
    n_steps=10,
)
x.name = "x"
y.name = "y"

x_vv = x.clone()
y_vv = y.clone()

logp_dict = aeppl.factorized_joint_logprob({x: x_vv, y: y_vv})
print(len(logp_dict))  # 2

logp_dict = aeppl.factorized_joint_logprob({x: x_vv})
print(len(logp_dict))  # 0

logp_dict = aeppl.factorized_joint_logprob({y: y_vv})
print(len(logp_dict))  # 0
@ricardoV94 ricardoV94 changed the title Scan logprob fails when not al RVs are valued Scan logprob fails when not all RVs are valued Apr 12, 2022
@brandonwillard brandonwillard added bug Something isn't working scan op-probability Involves the implementation of log-probabilities for Aesara `Op`s labels Apr 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working op-probability Involves the implementation of log-probabilities for Aesara `Op`s scan
Projects
None yet
Development

No branches or pull requests

2 participants