tensorflow::Env::DeleteDir()

Status tensorflow::Env::DeleteDir(const string &dirname) Deletes the specified directory.

tensorflow::Env::DeleteFile()

Status tensorflow::Env::DeleteFile(const string &fname) Deletes the named file.

tensorflow::Env::DeleteRecursively()

Status tensorflow::Env::DeleteRecursively(const string &dirname, int64 *undeleted_files, int64 *undeleted_dirs) Deletes the specified directory and all subdirectories and files underneath it. undeleted_files and undeleted_dirs stores the number of files and directories that weren't deleted (unspecified if the return status is not OK). REQUIRES: undeleted_files, undeleted_dirs to be not null. Typical return codes. OK - dirname exists and we were able to delete everything underneath. NOT_FOU

tensorflow::Env::GetChildren()

Status tensorflow::Env::GetChildren(const string &dir, std::vector< string > *result) Stores in *result the names of the children of the specified directory. The names are relative to "dir". Original contents of *results are dropped.

tensorflow::Env::GetFileSize()

Status tensorflow::Env::GetFileSize(const string &fname, uint64 *file_size) Stores the size of fname in *file_size.

tensorflow::Env::Env()

tensorflow::Env::Env()

tensorflow::Env::FileExists()

bool tensorflow::Env::FileExists(const string &fname) Returns true iff the named file exists.

tensorflow::Env::CreateDir()

Status tensorflow::Env::CreateDir(const string &dirname) Creates the specified directory.

tensorflow::Env

An interface used by the tensorflow implementation to access operating system functionality like the filesystem etc. Callers may wish to provide a custom Env object to get fine grain control. All Env implementations are safe for concurrent access from multiple threads without any external synchronization. Member Details tensorflow::Env::Env() virtual tensorflow::Env::~Env()=default Status tensorflow::Env::GetFileSystemForFile(const string &fname, FileSystem **result) Returns the FileSystem

tf.zeros_like()

tf.zeros_like(tensor, dtype=None, name=None, optimize=True) Creates a tensor with all elements set to zero. Given a single tensor (tensor), this operation returns a tensor of the same type and shape as tensor with all elements set to zero. Optionally, you can use dtype to specify a new type for the returned tensor. For example: # 'tensor' is [[1, 2, 3], [4, 5, 6]] tf.zeros_like(tensor) ==> [[0, 0, 0], [0, 0, 0]] Args: tensor: A Tensor. dtype: A type for the returned Tensor. Must be float3