A train running by is very, very different to a sonic boom. If you don't like the sound of a train, you can move a few hundred meters from the tracks and the inverse square law will do the rest. The sound of the train going by, even for people right next to the tracks, doesn't regularly break windows.