In somewhat of a response to your comment to Sammy’s post, the problem doesn’t restrict to five-degree rotations. The problem allows for all rotations.
An $8$ rotated 90 degrees is $\infty$ and no longer an $8$. Don’t train your neural net to see an $\infty$ and call it $8$.
A $6$ rotated 180 degrees is a $9$; a $9$ rotated 180 degrees is a $6$. Don’t train your neural net to mix up these. Unlike with $\infty$, there are $6$s and $9$s in your test data. If you allow for rotations of $6$s to $9$s and $9$s to $6$s, whatever improvements you see in being able to recognize the other digits may be offset by confusing $6$s and $9$s.
Similarly, consider a handwriting recognizer that confuses M and W.
“Dear Wom, Happy Wother’s Day!”
Or back to WNIST,$^{\dagger}$ “Dear Grandma, Happy 69th birthday! Next year we’ll go BASE jumping from the Burj Khalifa for your 100th!”
$^{\dagger}$Not a typo.