Refactored score graph code.

* Now only draws one graph, not one for each score type
* Graph drawing code may be called multiple times and will do the right thing
* Can now draw a subset of the races in a given graph
* Score data inserted into the template in a more compact (roughly x3) format

It has, however, lost the ability to permalink.