tf.io.write_file()

介绍

将 string类型的Tensor(其内容是二进制jpeg数据)保存到图片文件

一般搭配 tf.io.encode_jpeg() 使用

语法

tf.io.write_file(
    filename,
    contents,
    name=None
)
参数
  • filename:string 或 string类型的Tensor。要保存的文件名称。
  • contents:string类型的Tensor。其内容是二进制jpeg数据

例子

https://www.malaoshi.top/show_1EF54XrwrTkx.html


原文出处:/show_1EF54XsoXoKy.html