pyquil.quantum_processor.qcs module¶
- class pyquil.quantum_processor.qcs.QCSQuantumProcessor(quantum_processor_id: str, isa: qcs_api_client.models.instruction_set_architecture.InstructionSetArchitecture, noise_model: Optional[pyquil.noise.NoiseModel] = None)[source]¶
Bases:
pyquil.quantum_processor._base.AbstractQuantumProcessor
An AbstractQuantumProcessor initialized with an
InstructionSetArchitecture
returned from the QCS API. Notably, this class is able to serialize aCompilerISA
based on the architecture instructions.Initialize a new QCSQuantumProcessor.
- Parameters
quantum_processor_id – The id of the quantum processor.
isa – The QCS API
InstructionSetArchitecture
.noise_model – An optional
NoiseModel
for configuring a noisy quantum_processor on theQVM
.
- noise_model: Optional[pyquil.noise.NoiseModel]¶
- qubit_topology() networkx.classes.graph.Graph [source]¶
The connectivity of qubits in this quantum_processor given as a NetworkX graph.
- to_compiler_isa() pyquil.external.rpcq.CompilerISA [source]¶
Construct an ISA suitable for targeting by compilation. This will raise an exception if the requested ISA is not supported by the quantum_processor.
- pyquil.quantum_processor.qcs.get_qcs_quantum_processor(quantum_processor_id: str, client_configuration: Optional[qcs_api_client.client._configuration.configuration.QCSClientConfiguration] = None, timeout: float = 10.0) pyquil.quantum_processor.qcs.QCSQuantumProcessor [source]¶
Retrieve an instruction set architecture for the specified
quantum_processor_id
and initialize aQCSQuantumProcessor
with it.- Parameters
quantum_processor_id – QCS ID for the quantum processor.
timeout – Time limit for request, in seconds.
client_configuration – Optional client configuration. If none is provided, a default one will be loaded.
- Returns
A
QCSQuantumProcessor
with the requested ISA.