The figure of speech illustrated in the sentence is "metaphor".
A metaphor is used when making an implied comparison by describing an action that cannot be taken literally. In this case, we are comparing an action performed by students using the verb "stampeded" which is commonly used when animals suddently rush.
A simile is a comparison made using the words "like" or "as".
Personification means providing human qualities to non-human objects.