title: TensorFlow: Difference between EVAL and INFER
body: <p>What is the difference between <code>tf.contrib.learn.ModeKeys.EVAL</code> and <code>tf.contrib.learn.ModeKeys.INFER</code>?</p>
  
  <p>Also, how exactly are these used with the <code>tf.contrib.learn.Estimator</code> class object?</p>
  
  <p>I am attempting to follow this tutorial: <a href="https://www.tensorflow.org/tutorials/layers" rel="nofollow noreferrer">https://www.tensorflow.org/tutorials/layers</a>, and I am struggling to understand the purpose of each of these "modes".</p>
  
  <p>API documentation: <a href="https://www.tensorflow.org/api_docs/python/tf/contrib/learn/ModeKeys" rel="nofollow noreferrer">https://www.tensorflow.org/api_docs/python/tf/contrib/learn/ModeKeys</a></p>