import tensorflow as tf

            state = self.rnn_step(rnn_input, state)
            output = self.rnn_output(state)
            rnn_outputs.append(output)
            rnn_states.append(state)
        return tf.transpose(rnn_outputs, [1, 0, 2]), rnn_states


    def compute_predictions_scan(self):
