EstimatorQUIMB#
- class iqm.qaoa.backends.EstimatorQUIMB[source]#
Bases:
EstimatorBackend
The estimator class for calculating the expectation value using the tensor network package
quimb
.Methods
estimate
(qaoa_object)Calculates the expectation value of the Hamiltonian by contracting the RCC tensor networks in
quimb
.- 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).