RuntimeError: tf.placeholder() is not compatible with eager execution
Joyce121 opened this issue · 2 comments
Joyce121 commented
When I run the example command
"python motif_extractor.py experiments/nature_genetics_2008/1000_4/CNN/baseline_classification.json"
the RHSNet reported ”RuntimeError: tf.placeholder() is not compatible with eager execution“
Joyce121 commented
frankchen121212 commented
Dear Joyce,
According to your last issue, I assume that you are using Tensorflow v2.0 and higher,
Assume you are using Tensorflow 2.0 preview release which has eager execution enabled by default. There is a disable_eager_execution() in v1 API, which you can put in the front of your code like:
import tensorflow as tf
tf.compat.v1.disable_eager_execution()
Or, you need to downgrade your Tensorflow version to v1.12 according to README
conda install tensorflow-gpu==1.12.0 keras==2.2.4 cudatoolkit==9.0 cudnn=7.1.2 h5py