I doubt that it was the case here, but as cheap as good-quality cameras are today, I can see a railroad doing it to study wheel-rail dynamics in the real world. What better way to see how the stuff is actually working than to watch a video of it? Even if the camera gets broken by a piece of ballast all they've lost is a cheap camera.