# tf_agents.utils.eager_utils.clip_gradient_norms

<br />

|---|
| [![](https://www.tensorflow.org/images/GitHub-Mark-32px.png) View source on GitHub](https://github.com/tensorflow/agents/blob/v0.19.0/tf_agents/utils/eager_utils.py#L227-L246) |

Clips the gradients by the given value.

    tf_agents.utils.eager_utils.clip_gradient_norms(
        gradients_to_variables, max_norm
    )

<br />

<br />

<br />

| ## Args ||
|---|---|
| `gradients_to_variables` | A list of gradient to variable pairs (tuples). |
| `max_norm` | the maximum norm value. |

<br />

<br />

<br />

<br />

| ## Returns ||
|---|---|
| A list of clipped gradient to variable pairs. ||

<br />