How can I fix AttributeError: module 'tensorflow' has no attribute 'ConfigProto'

5.7k views Asked by At

I am new to deep learning and I get the following error when I try to run the command for image style transfer given in a tutorial I am using to learn.

python evaluate.py --checkpoint ./rain-princess.ckpt --in-path <path_to_input_file> --out-path ./output_image.jpg

I have scipy 1.1.0 installed. (downgraded to fix the issues AttributeError: module 'tensorflow' has no attribute 'imread').

I have Tensorflow installed. I have pillow installed.

Please note that I do not have the knowledge to edit any file, I am just copying the commands to see how it executes.

A screenshot of the error message

1

There are 1 answers

1
ArunJose On BEST ANSWER

This could be because you are using tensorflow 2.0 (when installing tensorflow by default it installs 2.0 now). Seems like your evaluvate.py file is suited to execute with tensorflow 1.* as it searches for configproto that is absent in 2.0 So downgrade tensorflow by

pip install tensorflow==1.14