pyquil.quantum_processor.qcs module¶
An implementation of AbstractQuantumProcessor based on an InstructionSetArchitecture returned from the QCS API.
- class pyquil.quantum_processor.qcs.QCSQuantumProcessor(quantum_processor_id: str, isa: InstructionSetArchitecture, noise_model: NoiseModel | None = None)[source]¶
Bases:
AbstractQuantumProcessor
An AbstractQuantumProcessor initialized with an
InstructionSetArchitecture
returned from the QCS API.Notably, this class is able to serialize a
CompilerISA
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: NoiseModel | None¶
- quantum_processor_id: str¶
- to_compiler_isa() CompilerISA [source]¶
Return a CompilerISA representation of the quantum_processor’s InstructionSetArchitecture.
- pyquil.quantum_processor.qcs.get_qcs_quantum_processor(quantum_processor_id: str, client_configuration: QCSClient | None = None, timeout: float = 10.0) QCSQuantumProcessor [source]¶
Retrieve an instruction set architecture for the specified QPU ID and initialize a
QCSQuantumProcessor
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.