We briefly discuss the relationship between several characterizations of the Hasse--Witt invariant of curves in characteristic $p$ with the goal of computing its value in concrete instances. We study its asymptotic behaviour when dealing with the geometric fibres of curves of genus $\geq 2$ defined over the rationals. Numerical evidence gathered for several modular curves supports certain conjectural distribution laws.
"On the Hasse-Witt invariants of modular curves." Experiment. Math. 6 (1) 57 - 76, 1997.