One rule decides the answer: a driver may cross railroad tracks only at a crossing, and must give way to a train, locomotive or rail trolley while doing so. A crossing is built for vehicles: it has a road surface over the tracks, signs, and often a gate, a traffic light or an attendant. Away from a crossing there is none of this, so such a place won't do, even if no train is in sight and the track seems clear