Could you post the error message with the complete stack trace?
It should point to the line of code, which raises the error, and you could then check the shape of the tensor inside this method to make sure it really has more than a single dimension.