Skip to main content
IBM Quantum Platform
Cette page provient d'une ancienne version de Qiskit SDK et n'existe pas dans la dernière version. Nous vous recommandons de passer à la dernière version. Voir les notes sur l'édition pour plus d'informations.

CircuitGradient

class qiskit.opflow.gradients.CircuitGradient

GitHub

Bases: ConverterBase

Deprecated: Circuit to gradient operator converter.

Converter for changing parameterized circuits into operators whose evaluation yields the gradient with respect to the circuit parameters.

This is distinct from DerivativeBase converters which take gradients of composite operators and handle things like differentiating combo_fn’s and enforcing product rules when operator coefficients are parameterized.

CircuitGradient - uses quantum techniques to get derivatives of circuits DerivativeBase - uses classical techniques to differentiate operator flow data structures

Deprecated since version 0.24.0

The class qiskit.opflow.gradients.circuit_gradients.circuit_gradient.CircuitGradient is deprecated as of qiskit-terra 0.24.0. It will be removed in the Qiskit 1.0 release. For code migration guidelines, visit https://qisk.it/opflow_migration.


Methods

convert

abstract convert(operator, params=None)

Parameters

Returns

An operator whose evaluation yields the Gradient.

Raises

ValueError – If params contains a parameter not present in operator.

Return type

OperatorBase

Cette page a-t-elle été utile ?
Signaler un bogue, une coquille ou proposer du contenu sur GitHub.