Controller mosfets act in the way you describe, they will temporaryily short out once thye get too hot.
Riding too slowly up gradients will produce the effect.
Tell tale sign of the mosfets cutting out is the controller is as hot to handle as a hot spud.