org.platanios.tensorflow.api.ops.variables
Adds ops to restore objects that are on the same shard.
Adds ops to restore objects that are on the same shard.
String tensor containing a single element. That element corresponds to the prefix of a
V2 checkpoint. For example, "/fs/train/ckpt-<step>/tmp/worker-
Sequence of saveable objects that the created op will restore.
Boolean value indicating whether to reshape loaded tensors to the shape of the corresponding saveable object.
Boolean value indicating whether to restore variables objects within a shard.
Name for the created op.
Created op.
Adds ops to save objects that are on the same shard and returns a tensor containing the filename used for the save operation.
Adds ops to save objects that are on the same shard and returns a tensor containing the filename used for the save operation.
String tensor containing a single element. That element corresponds to the prefix of a V2
checkpoint. For example, "/fs/train/ckpt-<step>/tmp/worker-
Sequence of saveable objects that the created op will save.
Name for the created op.
Scalar string tensor containing the filename used for the save operation.
Adds ops to restore sharded (per device) objects.
Adds ops to restore sharded (per device) objects.
String tensor containing a single element. That element corresponds to the prefix of a
V2 checkpoint. For example, "/fs/train/ckpt-<step>/tmp/worker-
Sequence of device-saveables pairs to restore, sorted by ascending device name. This is the result of the SaverDefBuilder.groupByDevice method.
Boolean value indicating whether to reshape loaded tensors to the shape of the corresponding saveable object.
Boolean value indicating whether to restore variables objects within a shard.
Name for the created op.
Created op.
Adds ops to save sharded (per device) objects.
Adds ops to save sharded (per device) objects.
Note that the sharded save procedure for the V2 checkpoint format is different than that for V1. There is a special "merge" step that merges the small metadata produced from each device.
String tensor containing a single element. That element corresponds to the prefix of a
V2 checkpoint. For example, "/fs/train/ckpt-<step>/tmp/worker-
Sequence of device-saveables pairs, sorted by ascending device name. This is the result of the SaverDefBuilder.groupByDevice method.
Scalar string tensor containing the filename used for the save operation.
Adds save/restore nodes to the graph and creates and returns a SaverDef proto.
Adds save/restore nodes to the graph and creates and returns a SaverDef proto.
Objects that need to be saved and loaded.
Boolean value which, if true
, allows restoring parameters from a checkpoint
where the parameters have a different shape. This is only needed when you try to
restore from a Dist-Belief checkpoint, and only some times.
Boolean value which, if true
, will shard the checkpoints, one per device that
is used by the provided saveables
.
Maximum number of checkpoints to keep. As new checkpoints are created, old ones
are deleted. If 0
, no checkpoints are deleted from the filesystem but only the
last one is kept in the checkpoint
file. Presently the number is only roughly
enforced. For example, in the case of restarts more than maxToKeep
checkpoints
may be kept.
Denotes how often checkpoints should be saved, in hour units. Defaults to 10,000 hours.
Boolean value which, if true
, causes the restoration of different variables to
happen sequentially within each device.
Filename used for the saveable objects saving and loading.
Name scope for the created ops.
Created SaverDef object.
Creates an op that restores the tensors that constitute saveable
.
Creates an op that restores the tensors that constitute saveable
.
Note that this method is intended to be overridden by subclasses that want to generate different types of ops.
String tensor containing a single element. That element corresponds to the prefix of a V2
checkpoint. For example, "/fs/train/ckpt-<step>/tmp/worker-
Saveable object that the created op will restore.
Name for the created op.
Created op outputs (restored tensors that constitute saveable
).
Creates an op that saves the provided sequence of saveables into a file.
Creates an op that saves the provided sequence of saveables into a file.
Note that this method is intended to be overridden by subclasses that want to generate different types of ops.
String tensor containing a single element. That element corresponds to the prefix of a V2
checkpoint. For example, "/fs/train/ckpt-<step>/tmp/worker-
Sequence of saveable objects that the created op will save.
Name for the created op.
Created op.
IllegalArgumentException
If an unsupported checkpoint format version is being used.
A saver builder is used to build SaverDef objects.
Most users shall never have to worry about dealing with saver builders. The Saver constructor uses DefaultSaverDefBuilder by default, which should be fine for most applications.