Tensorflow: Unable to open table file error -
with tensorflow 1.2.0, trying restore saved model receive error:
datalosserror (see above traceback): unable open table file checkpoints/saved_2/saved_2_model_1.meta: data loss: not sstable (bad magic number): perhaps file in different file format , need use different restore operator? [[node: save/restorev2_185 = restorev2[dtypes=[dt_int32], _device="/job:localhost/replica:0/task:0/cpu:0"](_arg_save/const_0_0, save/restorev2_185/tensor_names, save/restorev2_185/shape_and_slices)]]
i using same tensorflow version saving , restoring.
for saving:
saver = tf.train.saver() ckpt_dir = os.path.join(params['chk_path'], folder) if not os.path.exists(ckpt_dir): os.makedirs(ckpt_dir) ckpt_file = os.path.join(ckpt_dir, '{}'.format(name)) path = saver.save(sess, ckpt_file)
for restoring:
saver.restore(sess, ckpt_file)
i tried: model_saver = tf.train.saver(write_version = saver_pb2.saverdef.v1)
but same problem remains.
saver.restore(sess,tf.train.latest_checkpoint(ckpt_dir))
works
Comments
Post a Comment