Memoize badge data in StudentData.

Closes #522.