EquivalenceLibrary¶
- class EquivalenceLibrary(*, base=None)[ソース]¶
ベースクラス:
object
A library providing a one-way mapping of Gates to their equivalent implementations as QuantumCircuits.
Create a new equivalence library.
- パラメータ
base (Optional[EquivalenceLibrary]) – Base equivalence library to be referenced if an entry is not found in this library.
Methods
Add a new equivalence to the library.
Draws the equivalence relations available in the library.
Gets the set of QuantumCircuits circuits from the library which equivalently implement the given Gate.
Check if a library contains any decompositions for gate.
Return list of keys to key to node index map.
Return node index for a given key.
Set the equivalence record for a Gate.
Attributes
- graph¶
Return graph representing the equivalence library data.
This property should be treated as read-only as it provides a reference to the internal state of the
EquivalenceLibrary
object. If the graph returned by this property is mutated it could corrupt the the contents of the object. If you need to modify the outputPyDiGraph
be sure to make a copy prior to any modification.- 戻り値
A graph object with equivalence data in each node.
- 戻り値の型
PyDiGraph