Some San Rafael residents have been putting up with what they’ve called a rude awakening, the sounding of the SMART train’s horn as it conducts safety tests of the new tracks between the downtown San Rafael station and Larkspur Landing.

Sonoma-Marin Area Rail Transit management hopes to start service to the Larkspur ferry terminal before the end of the year. But first, it has to pass the important safety tests mandated by the Federal Railroad Administration.

As had been the case for much of the railroad tracks through Marin, the line had not seen any train traffic for decades. For the San Rafael-to-Larkspur tracks, it’s been a little longer. That means the public isn’t used to being cautious that a train might be on those tracks.

That’s one of the reasons why sounding the train’s horn is so important. It is about preventing accidents and saving lives.

The difference is that the safety-test runs are being conducted overnight, between 9:30 p.m. and 3:30 a.m.

SMART says it doesn’t have any spare or extra trains to use to conduct the tests during its normal operating schedule. That means a train, after its regular runs, needs to be used for the tests.

Interrupting daytime passenger service to conduct the tests would be an inconvenience to many SMART riders.

So San Rafael residents who live near the new stretch of tracks may have their sleep interrupted by the sound of SMART’s horns.

Fortunately, SMART is hopeful that the test will last only two to three weeks. District officials are working to come up with ways to respond to residents’ complaints.

The horns must sound at 96 decibels, about the same volume as a backyard power mower. The good news is that the horn is not a continuous roar.

Following the nighttime tests, SMART will run without passengers during normal service hours, but not late at night.

Local officials are awaiting federal approval of “quiet zone” designations for the new stretch, which will mean the train will not have to sound its horn at every crossing, just at the two stations.

San Rafael Mayor Gary Phillips, who serves as president of SMART’s board of directors, says he sees no alternative to the late-night safety tests, including using the train’s horn.

Understandably, some residents are upset about the interruption of their peace and quiet.

Fortunately, the testing will be brief. Safety precautions to avoid possible accidents and save lives seem to be worth a few weeks of enduring occasional train horns.