Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How can i train further using the pretrained checkpoint files? #40

Open
hemanthadawale opened this issue Aug 13, 2019 · 1 comment
Open

Comments

@hemanthadawale
Copy link

hemanthadawale commented Aug 13, 2019

I tried to load the checkpoint files for further training:
In train.py >
try: global_step = tf.contrib.framework.load_variable("model", "model.ckpt-300000") except Exception as err: global_step = 0

Gets called to checkpoint_utils.py >
def _get_checkpoint_filename(filepattern, name): """Returns checkpoint filename given directory or specific filepattern.""" if gfile.IsDirectory(filepattern): return saver.latest_checkpoint(filepattern, latest_filename = name) return filepattern

Gets called to saver.py >
def get_checkpoint_state(.....): try: if file_io.file_exists(coord_checkpoint_filename): print('*****file_io.file_exists******') file_content = file_io.read_file_to_string(coord_checkpoint_filename)

The file is not being detected.
But on specifying the complete path in train.py : (adding '.meta' or '.index' or '.data-00000-of-00001') >
global_step = tf.contrib.framework.load_variable("model", "model.ckpt-300000.meta")

the file is detected, but the next line 'file_io.read_file_to_string(coord_checkpoint_filename)' throws > " 'utf-8' codec can't decode byte 0xc3 in position 1: invalid continuation byte "

Can anyone help me out with this issue?
Thank you

@hemanthadawale
Copy link
Author

@leix28 please help if you know how to train further from checkpoints.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant