cirq_rigetti.circuit_transformers.build
This builds a CircuitTransformer
that the client may use over multiple sweeps of cirq.Sweepable
.
cirq_rigetti.circuit_transformers.build(
*,
qubits: Optional[Tuple[cirq.Qid, ...]] = None,
decompose_operation: Optional[Callable[[cirq.Operation], List[cirq.Operation]]] = None,
qubit_id_map: Optional[Dict[cirq.Qid, str]] = None,
post_transformation_hooks: Optional[List[_PostTransformationHook]] = None
) -> cirq_rigetti.circuit_transformers.CircuitTransformer
Args |
qubits
|
The qubits defined on the circuit that this function will transform. If None,
the transformer will pull qubits from the cirq.Circuit and order them by
cirq.ops.QubitOrder.DEFAULT on each transformation.
|
decompose_operation
|
A callable that can decompose each individual operation on the
cirq.Circuit before being transformed. This will override the default Quil
decompositions in cirq. You may optimize your circuit before transformation and pass
a no-op here.
|
qubit_id_map
|
A map of cirq.Qid to physical qubit addresses that will end up in
the executed native Quil.
|
post_transformation_hooks
|
A list of transformation functions you may pass to further
convert a pyquil.Program after transformation.
|
Returns |
A CircuitTransformer transforming the cirq.Circuit s as specified above.
|
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-06-27 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-06-27 UTC."],[],[]]