contrib.training.multiply_gradients

tf.contrib.training.multiply_gradients

tf.contrib.training.multiply_gradients

multiply_gradients(
    grads_and_vars,
    gradient_multipliers
)

Defined in tensorflow/contrib/training/python/training/training.py.

Multiply specified gradients.

Args:

  • grads_and_vars: A list of gradient to variable pairs (tuples).
  • gradient_multipliers: A map from either Variables or Variable op names to the coefficient by which the associated gradient should be scaled.

Returns:

The updated list of gradient to variable pairs.

Raises:

  • ValueError: If grads_and_vars is not a list or if gradient_multipliers is empty or None or if gradient_multipliers is not a dictionary.

© 2017 The TensorFlow Authors. All rights reserved.
Licensed under the Creative Commons Attribution License 3.0.
Code samples licensed under the Apache 2.0 License.
https://www.tensorflow.org/api_docs/python/tf/contrib/training/multiply_gradients

在线笔记
App下载
App下载

扫描二维码

下载编程狮App

公众号
微信公众号

编程狮公众号

意见反馈
返回顶部