QFI¶
- class QFI(qgt, precision=None)[source]¶
Bases:
ABC
Computes the Quantum Fisher Information (QFI) given a pure, parameterized quantum state. QFI is defined as:
\[\mathrm{QFI}_{ij}= 4 \mathrm{Re}[\langle \partial_i \psi | \partial_j \psi \rangle - \langle\partial_i \psi | \psi \rangle \langle\psi | \partial_j \psi \rangle].\]- Parameters:
Attributes
- precision¶
Return the precision used by the run method of the BaseQGT’s Estimator primitive. If None, the default precision of the primitive is used.
- Returns:
The default precision.
Methods
- run(circuits, parameter_values, parameters=None, *, precision=None)[source]¶
Run the job of the QFIs on the given circuits.
- Parameters:
circuits (Sequence[QuantumCircuit]) – The list of quantum circuits to compute the QFIs.
parameter_values (Sequence[Sequence[float]]) – The list of parameter values to be bound to the circuit.
parameters (Sequence[Sequence[Parameter] | None] | None) – The sequence of parameters to calculate only the QFIs of the specified parameters. Each sequence of parameters corresponds to a circuit in
circuits
. Defaults to None, which means that the QFIs of all parameters in each circuit are calculated.precision (float | Sequence[float] | None) – Precision to be used by the underlying Estimator. If a single float is provided, this number will be used for all circuits. If a sequence of floats is provided, they will be used on a per-circuit basis. If not set, the gradient’s default precision will be used for all circuits, and if that is None (not set) then the underlying primitive’s (default) precision will be used for all circuits.
- Returns:
The job object of the QFIs of the expectation values. The i-th result corresponds to
circuits[i]
evaluated with parameters bound asparameter_values[i]
.- Return type: