Saver

AutoDist Saver.

class Saver(var_list=None, reshape=False, sharded=False, max_to_keep=5, keep_checkpoint_every_n_hours=10000.0, name=None, restore_sequentially=False, saver_def=None, builder=None, defer_build=False, allow_empty=False, write_version=2, pad_step_number=False, save_relative_paths=False, filename=None)[source]

Bases: tensorflow.python.training.saver.Saver

A wrapper upon tf.compat.v1.train.Saver.

save(sess, save_path, global_step=None, latest_filename=None, meta_graph_suffix='meta', write_meta_graph=True, write_state=True, strip_default_attrs=False, save_debug_info=False)[source]

Save the checkpoint to “save_path” using the saver managed by AutoDist.

Follows the same signature with tf.saver save().

restore(sess, save_path)[source]

Restore the checkpoint from “save_path” using the saver managed by AutoDist.

Follows the same signature with tf.saver restore().