Abstract analog backend functions
BaseQuTiPObservablesParser
Convert InputType object to Qutip native quantum objects for simulation on QuTiP.
It is intended to be used on the expectation method of Pulser-based interface classes. InputType can be qadence2-expressions expression or any other module with the same methods.
build(num_qubits, observables)
classmethod
Parses an input expression or list of expressions into a native QuTiP object.
PARAMETER | DESCRIPTION |
---|---|
num_qubits
|
the number of qubits to create the qutip object to
TYPE:
|
observables
|
the input expression. Any qadence2-expressions expression compatible object, with the same methods
TYPE:
|
RETURNS | DESCRIPTION |
---|---|
list[Qobj]
|
A QuTiP object with the Hilbert space compatible with |
Source code in qadence2_platforms/backends/_base_analog/functions.py
base_parse_native_observables(num_qubits, observable)
Function to be called by Interface
's expectation
method on Pulser-based backends
using QuTiP emulator.
PARAMETER | DESCRIPTION |
---|---|
num_qubits
|
number of qubits
TYPE:
|
observable
|
the input expression. Any qadence2-expressions expression compatible object, with the same methods, or a list of it
TYPE:
|
RETURNS | DESCRIPTION |
---|---|
list[Qobj]
|
A QuTiP object with the Hilbert space compatible with |