Skip to content

Commit 49cab31

Browse files
committed
remove duplicate check
1 parent ac6f89e commit 49cab31

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

pytensor/tensor/rewriting/math.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -561,9 +561,8 @@ def local_log_sqrt(fgraph, node):
561561
return
562562

563563
prev_op = x.owner.op.scalar_op
564-
node_op = node.op.scalar_op
565564

566-
if isinstance(prev_op, ps.Sqrt) and isinstance(node_op, ps.Log):
565+
if isinstance(prev_op, ps.Sqrt):
567566
# Case for log(sqrt(x)) -> 0.5 * log(x)
568567
x = x.owner.inputs[0]
569568
old_out = node.outputs[0]

0 commit comments

Comments
 (0)