Dealing with the filesystem

tf.matching_files(pattern, name=None)

Returns the set of files matching a pattern.

Note that this routine only supports wildcard characters in the basename portion of the pattern, not in the directory portion.

Args:
  • pattern: A Tensor of type string. A (scalar) shell wildcard pattern.
  • name: A name for the operation (optional).
Returns:

A Tensor of type string. A vector of matching filenames.


tf.read_file(filename, name=None)

Reads and outputs the entire contents of the input filename.

Args:
  • filename: A Tensor of type string.
  • name: A name for the operation (optional).
Returns:

A Tensor of type string.