class_docstr: Represents a quantum circuit as a directed acyclic graph.
  
  In this representation the :class:`~.Operator` instances are the nodes of the graph,
  and each directed edge represent a subsystem (or a group of subsystems) on which the two
  Operators act subsequently. This representation can describe the causal relationships
  between arbitrary quantum channels and measurements, not just unitary gates.
  
  Args:
      ops (Iterable[.Operator]): quantum operators constituting the circuit, in temporal order
      obs (Iterable[.MeasurementProcess]): terminal measurements, in temporal order
      wires (.Wires): The addressable wire registers of the device that will be executing this graph
      par_info (list[dict]): Parameter information. For each index, the entry is a dictionary containing an operation
      and an index into that operation's parameters.
      trainable_params (set[int]): A set containing the indices of parameters that support
          differentiability. The indices provided match the order of appearence in the
          quantum circuit.
class_docstr_tok: ["Represents","a","quantum","circuit","as","a","directed","acyclic","graph",".","In","this","representation","the",":","class",":","`","~.Operator","`","instances","are","the","nodes","of","the","graph",",","and","each","directed","edge","represent","a","subsystem","(","or","a","group","of","subsystems",")","on","which","the","two","Operators","act","subsequently",".","This","representation","can","describe","the","causal","relationships","between","arbitrary","quantum","channels","and","measurements",",","not","just","unitary","gates",".","Args",":","ops","(","Iterable","[",".Operator","]",")",":","quantum","operators","constituting","the","circuit",",","in","temporal","order","obs","(","Iterable","[",".MeasurementProcess","]",")",":","terminal","measurements",",","in","temporal","order","wires","(",".Wires",")",":","The","addressable","wire","registers","of","the","device","that","will","be","executing","this","graph","par_info","(","list","[","dict","]",")",":","Parameter","information",".","For","each","index",",","the","entry","is","a","dictionary","containing","an","operation","and","an","index","into","that","operation","'s","parameters",".","trainable_params","(","set","[","int","]",")",":","A","set","containing","the","indices","of","parameters","that","support","differentiability",".","The","indices","provided","match","the","order","of","appearence","in","the","quantum","circuit","."]
docstr: Nodes on all the directed paths between the two given nodes.
  
  Returns the set of all nodes ``s`` that fulfill :math:`a \le s \le b`.
  There is a directed path from ``a`` via ``s`` to ``b`` iff the set is nonempty.
  The endpoints belong to the path.
  
  Args:
      a (Operator): initial node
      b (Operator): final node
  
  Returns:
      list[Operator]: nodes on all the directed paths between a and b
docstr_tok: ["Nodes","on","all","the","directed","paths","between","the","two","given","nodes",".","Returns","the","set","of","all","nodes","``","s","``","that","fulfill",":","math",":","`","a","\\le","s","\\le","b","`",".","There","is","a","directed","path","from","``","a","``","via","``","s","``","to","``","b","``","iff","the","set","is","nonempty",".","The","endpoints","belong","to","the","path",".","Args",":","a","(","Operator",")",":","initial","node","b","(","Operator",")",":","final","node","Returns",":","list","[","Operator","]",":","nodes","on","all","the","directed","paths","between","a","and","b"]
code: def nodes_between(self, a, b):
      r"""Nodes on all the directed paths between the two given nodes.
  
      Returns the set of all nodes ``s`` that fulfill :math:`a \le s \le b`.
      There is a directed path from ``a`` via ``s`` to ``b`` iff the set is nonempty.
      The endpoints belong to the path.
  
      Args:
          a (Operator): initial node
          b (Operator): final node
  
      Returns:
          list[Operator]: nodes on all the directed paths between a and b
      """
      A = self.descendants([a])
      A.append(a)
      B = self.ancestors([b])
      B.append(b)
  
      return [
          B.pop(i) for op1 in A for i, op2 in enumerate(B) if op1 is op2
      ]
  
imports: from numbers import Number
  from collections import namedtuple
  import numpy
  import rustworkx
  from pennylane.measurements import MeasurementProcess
  from pennylane.resource import ResourcesOperation
label_desc: Use image node_id 16 for calling the CircuitGraph obj's underlying member method code with example usage: obj.nodes_between(a, b) and returns: unknown