File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
pytensor/tensor/rewriting Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -583,10 +583,10 @@ def rewrite_inv_inv(fgraph, node):
583
583
if potential_inner_inv is None or potential_inner_inv .op is None :
584
584
return None
585
585
# Check if its an inner solve as well, does that have b = eye
586
- solve_inv_check = True if hasattr ( potential_inner_inv . op , "core_op" ) else False
587
- # if potential_inner_inv.op and isinstance(potential_inner_inv.op, DimShuffle):
588
- # return None
589
- if solve_inv_check and isinstance ( potential_inner_inv . op . core_op , valid_solves ):
586
+ solve_inv_check = False
587
+ if hasattr ( potential_inner_inv .op , "core_op" ) and isinstance (
588
+ potential_inner_inv . op . core_op , valid_solves
589
+ ):
590
590
solve_inv_check = _find_solve_with_eye (potential_inner_inv )
591
591
if not solve_inv_check :
592
592
return None
You can’t perform that action at this time.
0 commit comments