How do I disable TensorFlow's eager execution?

后端 未结 4 1906
無奈伤痛
無奈伤痛 2020-12-02 16:47

I am trying to learn TensorFlow. Currently, I am working with placeholders. When I tried to create the placeholder, I got an error: RuntimeError: tf.placeholder() is n

4条回答
  •  忘掉有多难
    2020-12-02 17:04

    In TensorFlow 2.3, you can disable eager mode anytime using the following method:

    import tensorflow as tf
    
    tf.config.run_functions_eagerly(False)
    

提交回复
热议问题