Creates a dataset that caches elements from `input_dataset`.
A CacheDataset will iterate over the input_dataset, and store tensors. If the cache already exists, the cache will be used. If the cache is inappropriate (e.g. cannot be opened, contains tensors of the wrong shape / size), an error will the returned when used.
Constants
String | OP_NAME | The name of this op, as known by TensorFlow core engine |
Public Methods
Output<TType> |
asOutput()
Returns the symbolic handle of the tensor.
|
static CacheDataset | |
Output<?> |
handle()
|
Inherited Methods
Constants
public static final String OP_NAME
The name of this op, as known by TensorFlow core engine
Public Methods
public Output<TType> asOutput ()
Returns the symbolic handle of the tensor.
Inputs to TensorFlow operations are outputs of another TensorFlow operation. This method is used to obtain a symbolic handle that represents the computation of the input.
public static CacheDataset create (Scope scope, Operand<?> inputDataset, Operand<TString> filename, List<Class<? extends TType>> outputTypes, List<Shape> outputShapes)
Factory method to create a class wrapping a new CacheDataset operation.
Parameters
scope | current scope |
---|---|
filename | A path on the filesystem where we should cache the dataset. Note: this will be a directory. |
Returns
- a new instance of CacheDataset