I think I might have found the culprit. The magnet had drifted a bit relative to its original position. So it's probable that the "counter" (not sure what the right term for it is) ends up occasionally missing a wheel revolution. I say this b/c I noticed how the instantaneous speed would occasionally gyrate wildly when I knew I was going at a more or less constant speed.