EstimatorQUIMB#
Module: iqm.qaoa.backends
- class iqm.qaoa.backends.EstimatorQUIMB[source]#
Bases:
EstimatorBackendThe estimator class for calculating the expectation value using the tensor network package
quimb.Attributes
CRIT_DEGMethods
Calculates the expectation value of the Hamiltonian by contracting the RCC tensor networks in
quimb.The method for estimating the exp.
- estimate(qaoa_object)[source]#
Calculates the expectation value of the Hamiltonian by contracting the RCC tensor networks in
quimb.Uses
quimb_tn()to build aCircuit. This object represents the QAOA circuit, so it can be used to calculate expectation values (using the functionlocal_expectation()). The local expectation values are added to get the expectation value of the full Hamiltonian. The calculation includes a constant term (coming from the translation of a QUBO problem to a Hamiltonian).
- estimate_correlations_z(qaoa_object, target_qubits)[source]#
The method for estimating the exp. value of products of Z operators on
target_qubits.The correlations are calculated natively for QUIMB, as a contraction of tensor networks, very similarly to how the expectation value of the Hamiltonian is estimated in
estimate().- Parameters:
- Returns:
The estimated expected value of product of Z operators on given
target_qubits. Or a list of those, iftarget_qubitswas given as a list.- Return type:
Inheritance
