We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent eb19200 commit 55090f7Copy full SHA for 55090f7
pytensor/tensor/extra_ops.py
@@ -1564,7 +1564,7 @@ def broadcast_shape_iter(
1564
(one,) * (max_dims - len(a))
1565
+ tuple(
1566
one
1567
- if sh == 1 or isinstance(sh, Constant) and sh.value == 1
+ if sh == 1 or isinstance(sh, Constant) and sh.data == 1
1568
else (ps.as_scalar(sh) if not isinstance(sh, Variable) else sh)
1569
for sh in a
1570
)
@@ -1603,7 +1603,7 @@ def broadcast_shape_iter(
1603
const_nb_shapes: set[Variable] = set()
1604
for shape in non_bcast_shapes:
1605
if isinstance(shape, Constant):
1606
- const_nb_shapes.add(shape.value.item())
+ const_nb_shapes.add(shape.data.item())
1607
else:
1608
nonconst_nb_shapes.add(shape)
1609
0 commit comments