output = F.log_softmax(self.out(torch.cat((rnn_output, context), 2)), dim=1)
TypeError: log_softmax() got an unexpected keyword argument 'dim'

The doc is:
Parameters:	
input (Variable) – input
dim (int) – A dimension along which log_softmax will be computed.

The error of getting an unexpected keyword argument ‘dim’ is weird.
what is the reason of it?