Print the prediction of convolutional neural network
You can replace these lines:

opt = sess.run(optimizer, feed_dict={x: batch_x,
                                     y: batch_y})
loss, acc = sess.run([cost, accuracy], feed_dict={x: batch_x,
                                                  y: batch_y})


by:

opt_, loss_, acc_, out_ = sess.run([optimizer, cost, accuracy, out], feed_dict={x:batch_x,
                                                  y: batch_y})


In this way, you can evaluate all the parameters given in the list (optimizer, cost, accuracy, out) in a single sess.run(). After, if it is classification task, you will probably need to apply softmax and argmin to out_