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

The model file .mata I've trained 52 epoch on Citycapes can't be used in compress single image #30

Open
RaysonSJTU opened this issue May 22, 2019 · 1 comment

Comments

@RaysonSJTU
Copy link

The model .mata I've trained 52 epoch on Citycapes can't be used in compress single image, and the storage of mata is 7823KB, which is not similar to noiseMScsC8_epoch15.ckpt-15.meta 24880KB. Did I trained in the wrong way? Lookingfoward you response, thank you.

@RaysonSJTU
Copy link
Author

RaysonSJTU commented May 22, 2019

When I use 52 epoch model file my_network_last.ckpt-52.meta to compress single image:

compress.py -r "/home/shr/generative-compression-master/checkpoints/my_network_last.ckpt-52" -i "/home/shr/generative-compression-master/kodim22.png" -o "/home/shr/generative-compression-master/522.png"

the Error happend:
Traceback (most recent call last):
File "compress.py", line 80, in
main()
File "compress.py", line 77, in main
single_compress(config_test, args)
File "compress.py", line 48, in single_compress
new_saver = tf.train.import_meta_graph('{}.meta'.format(args.restore_path))
File "/home/shr/anaconda3/lib/python3.6/site-packages/tensorflow/python/training/saver.py", line 1955, in import_meta_graph
**kwargs)
File "/home/shr/anaconda3/lib/python3.6/site-packages/tensorflow/python/framework/meta_graph.py", line 743, in import_scoped_meta_graph
producer_op_list=producer_op_list)
File "/home/shr/anaconda3/lib/python3.6/site-packages/tensorflow/python/util/deprecation.py", line 432, in new_func
return func(*args, **kwargs)
File "/home/shr/anaconda3/lib/python3.6/site-packages/tensorflow/python/framework/importer.py", line 460, in import_graph_def
_RemoveDefaultAttrs(op_dict, producer_op_list, graph_def)
File "/home/shr/anaconda3/lib/python3.6/site-packages/tensorflow/python/framework/importer.py", line 227, in _RemoveDefaultAttrs
op_def = op_dict[node.op]
KeyError: 'BatchDatasetV2'

How can I do it, if I train the model in a wrong way?

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