It's not done on an individual basis.
Let's say there are 1000 students studying a particular course.
For each student, their average mark over all of the subjects they take is calculated.
Then, each of those 1000 average marks is averaged.
If this average is high, the candidature is strong, and so the course is scaled up (because it would be harder for an average student to obtain a high rank in that course).
Similarly, if the average is low, the candidature is weak, and so the course is scaled down (because it would be easier for an average student to obtain a high rank in that course).