TensorFlow函数:tf.to_bfloat16

2018-03-31 14:05 更新

tf.to_bfloat16函数

tf.to_bfloat16(
    x,
    name='ToBFloat16'
)

定义在:tensorflow/python/ops/math_ops.py.

参见指南:张量转换

将张量转换为 bfloat16 类型.

函数参数:

  • x:一个 Tensor 或 SparseTensor.
  • name:操作的名称(可选).

函数返回值:

tf.to_bfloat16函数返回一个 Tensor 或 SparseTensor 与 x(类型为 bfloat16)具有相同的形状.

可能引发的异常:

  • TypeError:如果 x 不能转换为 bfloat16. 
以上内容是否对您有帮助:
在线笔记
App下载
App下载

扫描二维码

下载编程狮App

公众号
微信公众号

编程狮公众号

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy