Skip to content

Commit 9db17f6

Browse files
committed
add comments
1 parent 6b7c11b commit 9db17f6

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

pymc/distributions/distribution.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -687,8 +687,10 @@ def dist_moment(rv, size, *dist_params):
687687
fgraph = rv.owner.op.fgraph.clone()
688688
replace_moments = MomentRewrite()
689689
replace_moments.rewrite(fgraph)
690+
# we need to replace dummy variable by actual dist params
690691
for i, par in enumerate([size] + list(dist_params)):
691692
fgraph.replace(fgraph.inputs[i], par)
693+
# we need to replace dymmy random generators in Scan node inputs
692694
for node in fgraph.toposort():
693695
if isinstance(node.op, Scan):
694696
for inp in node.inputs:

0 commit comments

Comments
 (0)