code: def cond_merge_ifs_true(fgraph, node):
      op = node.op
      if not isinstance(op, IfElse):
          return False
      t_ins = node.inputs[1:][: op.n_outs]
  
      replace = {}
      for idx, tval in enumerate(t_ins):
          if (
              tval.owner
              and isinstance(tval.owner.op, IfElse)
              and tval.owner.inputs[0] == node.inputs[0]
          ):
              ins_op = tval.owner.op
              ins_t = tval.owner.inputs[1:][: ins_op.n_outs]
              replace[idx + 1] = ins_t[tval.owner.outputs.index(tval)]
  
      if len(replace) == 0:
          return False
  
      old_ins = list(node.inputs)
      for pos, var in replace.items():
          old_ins[pos] = var
      return op(*old_ins, return_list=True)
  
imports: from collections.abc import Sequence
  from copy import deepcopy
  from typing import TYPE_CHECKING, Any, Optional, Union
  import numpy
  import pytensor.tensor
  from pytensor import as_symbolic
  from pytensor.compile import optdb
  from pytensor.configdefaults import config
  from pytensor.graph.basic import Apply, Variable, apply_depends_on
  from pytensor.graph.op import _NoPythonOp
  from pytensor.graph.replace import clone_replace
  from pytensor.graph.rewriting.basic import GraphRewriter, in2out, node_rewriter
  from pytensor.graph.type import HasDataType, HasShape
  from pytensor.tensor.shape import Reshape, Shape, SpecifyShape, Unbroadcast
label_desc: Use image node_id 4 for calling a global function with example usage: cond_merge_ifs_true(fgraph, node) and returns: op, False, False