title: Tensorflow: Use same dequeued batch at different locations in graph
body: <p>I have a working input pipeline that uses multiple threads to read data from tfrecords files, decodes and preprocesses the data, and serves them to the graph. I used <a href="https://github.com/tensorflow/models/tree/master/inception" rel="nofollow noreferrer">this</a> example as a starting point. My problem is that I need the input batch again in the loss layer, to compute a reconstruction error of the input. If I now just add the dequeuing operation multiple times to my graph, i.e. once at the input layer and once at the loss layer, I obviously get two times a different batch since tensorflow evaluates the operation twice. What is the easiest way to overcome this?</p>