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

Error when compress a single image #29

Open
CGod1991 opened this issue Mar 29, 2019 · 1 comment
Open

Error when compress a single image #29

CGod1991 opened this issue Mar 29, 2019 · 1 comment

Comments

@CGod1991
Copy link

I was compress a single image according the "Usage" part , but got this error:
Traceback (most recent call last): File "/home/xx/PycharmProjects/generative-compression-master/compress.py", line 79, in <module> main() File "/home/xx/PycharmProjects/generative-compression-master/compress.py", line 76, in main single_compress(config_test, args) File "/home/xx/PycharmProjects/generative-compression-master/compress.py", line 18, in single_compress ckpt = tf.train.get_checkpoint_state(directories.checkpoints, latest_filename='noiseMScsC8_epoch15.ckpt-15.data-00000-of-00001') File "/home/xx/anaconda3/lib/python3.6/site-packages/tensorflow/python/training/checkpoint_management.py", line 273, in get_checkpoint_state coord_checkpoint_filename) File "/home/xx/anaconda3/lib/python3.6/site-packages/tensorflow/python/lib/io/file_io.py", line 331, in read_file_to_string return f.read() File "/home/xx/anaconda3/lib/python3.6/site-packages/tensorflow/python/lib/io/file_io.py", line 132, in read pywrap_tensorflow.ReadFromStream(self._read_buf, length, status)) File "/home/xx/anaconda3/lib/python3.6/site-packages/tensorflow/python/lib/io/file_io.py", line 100, in _prepare_value return compat.as_str_any(val) File "/home/xx/anaconda3/lib/python3.6/site-packages/tensorflow/python/util/compat.py", line 107, in as_str_any return as_str(value) File "/home/xx/anaconda3/lib/python3.6/site-packages/tensorflow/python/util/compat.py", line 80, in as_text return bytes_or_text.decode(encoding) UnicodeDecodeError: 'utf-8' codec can't decode byte 0xd5 in position 25: invalid continuation byte

It sames the ckpt file has some problem. Did i miss something?

PS:
My os encoding is utf-8.
This is my command: python compress.py -r ./checkpoints -i ./test_img -o ./output

Best regards.

@madisa1
Copy link

madisa1 commented Apr 6, 2020

@CGod1991 I have the same issue, did you resolve it ?

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

2 participants