---
title: GradientDescentState (v0.46)
description: API reference for qiskit.algorithms.optimizers.GradientDescentState in qiskit v0.46
source: https://eu-de.quantum.cloud.ibm.com/docs/en/api/qiskit/0.46/qiskit.algorithms.optimizers.GradientDescentState
---

# GradientDescentState

*class* `qiskit.algorithms.optimizers.GradientDescentState(x, fun, jac, nfev, njev, nit, stepsize, learning_rate)`

[GitHub](https://github.com/qiskit/qiskit/tree/stable/0.46/qiskit/algorithms/optimizers/gradient_descent.py)

Bases: [`OptimizerState`](/docs/api/qiskit/0.46/qiskit.algorithms.optimizers.OptimizerState "qiskit.algorithms.optimizers.steppable_optimizer.OptimizerState")

State of [`GradientDescent`](/docs/api/qiskit/0.46/qiskit.algorithms.optimizers.GradientDescent "qiskit.algorithms.optimizers.GradientDescent").

Dataclass with all the information of an optimizer plus the learning\_rate and the stepsize.

## Attributes

### stepsize

Type: `float | None`

Norm of the gradient on the last step.

### learning\_rate

Type: `LearningRate`

Learning rate at the current step of the optimization process.

It behaves like a generator, (use `next(learning_rate)` to get the learning rate for the next step) but it can also return the current learning rate with `learning_rate.current`.

### x

Type: `POINT`

Current optimization parameters.

### fun

Type: `Callable[[POINT], float] | None`

Function being optimized.

### jac

Type: `Callable[[POINT], POINT] | None`

Jacobian of the function being optimized.

### nfev

Type: `int | None`

Number of function evaluations so far in the optimization.

### njev

Type: `int | None`

Number of jacobian evaluations so far in the opimization.

### nit

Type: `int | None`

Number of optimization steps performed so far in the optimization.
