Remove/avoid deprecation warnings in 2.x saving utilities
Having the warning on little-used 1.x utilities isn't super important, but the 2.x utilities shouldn't print them during normal use for sure. PiperOrigin-RevId: 225047956
This commit is contained in:
parent
cf9878d6a6
commit
316660063a
@ -56,10 +56,6 @@ def _GetCheckpointFilename(save_dir, latest_filename):
|
|||||||
return os.path.join(save_dir, latest_filename)
|
return os.path.join(save_dir, latest_filename)
|
||||||
|
|
||||||
|
|
||||||
@deprecation.deprecated(
|
|
||||||
date=None,
|
|
||||||
instructions=("Use tf.train.CheckpointManager to manage checkpoints rather "
|
|
||||||
"than editing the Checkpoint proto manually."))
|
|
||||||
@tf_export(v1=["train.generate_checkpoint_state_proto"])
|
@tf_export(v1=["train.generate_checkpoint_state_proto"])
|
||||||
def generate_checkpoint_state_proto(save_dir,
|
def generate_checkpoint_state_proto(save_dir,
|
||||||
model_checkpoint_path,
|
model_checkpoint_path,
|
||||||
|
@ -1863,7 +1863,7 @@ class Checkpoint(tracking.Checkpointable):
|
|||||||
checkpoint_number = assign_op.numpy()
|
checkpoint_number = assign_op.numpy()
|
||||||
file_path = self.write("%s-%d" % (file_prefix, checkpoint_number),
|
file_path = self.write("%s-%d" % (file_prefix, checkpoint_number),
|
||||||
session=session)
|
session=session)
|
||||||
checkpoint_management.update_checkpoint_state(
|
checkpoint_management.update_checkpoint_state_internal(
|
||||||
save_dir=os.path.dirname(file_prefix),
|
save_dir=os.path.dirname(file_prefix),
|
||||||
model_checkpoint_path=file_path,
|
model_checkpoint_path=file_path,
|
||||||
all_model_checkpoint_paths=[file_path])
|
all_model_checkpoint_paths=[file_path])
|
||||||
|
Loading…
Reference in New Issue
Block a user