That is one awful rail crossing. The shoulder leading into it disappears into a narrow wheel catcher....nasty. There is only two ways to make that crossing. On foot or take the lane. You fall with traffic next to you and you are probably dead.
The rider crossing in the middle was probably trying to minimize those risks.