BaseEstimator
class BaseEstimator(circuits, observables, parameters=None)
Bases: abc.ABC
Estimator base class.
Base class for Estimator that estimates expectation values of quantum circuits and observables.
Creating an instance of an Estimator, or using one in a with
context opens a session that holds resources until the instance is close()
ed or the context is exited.
Parameters
- circuits – quantum circuits that represent quantum states
- observables – observables
- parameters – parameters of quantum circuits, specifying the order in which values
- be bound. (will) – Defaults to
[circ.parameters for circ in circuits]
The indexing is such thatparameters[i, j]
is the j-th formal parameter ofcircuits[i]
.
Raises
QiskitError – for mismatch of circuits and parameters list.
Methods
close
abstract BaseEstimator.close()
Close the session and free resources
Attributes
circuits
Quantum circuits that represents quantum states.
Returns
quantum circuits
observables
Observables to be estimated
Returns
observables
parameters
Parameters of quantum circuits
Returns
parameters, where parameters[i][j]
is the j-th parameter of the i-th circuit.
Was this page helpful?
Report a bug or request content on GitHub.