After
x, h = self.rnn(x)`

x has the shape (seq_len, batch, hidden_size), in your case (101, 32, hidden_size), since the output contains the hidden states for ALL 101 time steps.
The most obvious solution would to to use only the last hidden state. So you can either do


self.op(x[-1]) or
self.op(h[-1])

In your case, both x[-1] and h[-1] will have the shape (batch, hidden_size), in your case (32, hidden_size).
The output of the self.op layer will be (batch_size, num_classes), in your case (32, 32), exactly what you want.
The last change you need to do is to change dim=2 to dim=1 in your definition of the Softmax layer.