contrib.framework.reduce_sum_n

tf.contrib.framework.reduce_sum_n

tf.contrib.framework.reduce_sum_n

reduce_sum_n(
    tensors,
    name=None
)

Defined in tensorflow/contrib/framework/python/framework/tensor_util.py.

See the guide: Framework (contrib)

Reduce tensors to a scalar sum.

This reduces each tensor in tensors to a scalar via tf.reduce_sum, then adds them via tf.add_n.

Args:

  • tensors: List of tensors, all of the same numeric type.
  • name: Tensor name, and scope for all other ops.

Returns:

Total loss tensor, or None if no losses have been configured.

Raises:

  • ValueError: if losses is missing or empty.

© 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/framework/reduce_sum_n

在线笔记
App下载
App下载

扫描二维码

下载编程狮App

公众号
微信公众号

编程狮公众号

意见反馈
返回顶部