title: How do I use tf.reshape()?
body: <pre><code>import tensorflow as tf    
  import random    
  import numpy as np    
  
  x = tf.placeholder('float')   
  x = tf.reshape(x, [-1,28,28,1])
  
  with tf.Session() as sess:
      x1 = np.asarray([random.uniform(0,1) for i in range(784)])
      result = sess.run(x, feed_dict={x: x1})
      print(result)
  </code></pre>
  
  <p>I had some problems using mnist data on reshaping, but this question is simplified version of my problem...
  Why actually isn't this code working? </p>
  
  <p>It shows </p>
  
  <blockquote>
    <p>"ValueError: Cannot feed value of shape (784,) for Tensor 'Reshape:0', which has shape '(?, 28, 28, 1)' ".</p>
  </blockquote>
  
  <p>How could I solve it?</p>