What is this?

WATCH: Authorities address the collision and derailment between a CN Rail freight train and a Wisconsin Southern train Sunday night

SLINGER, Wis. – A Canadian National Railway Co. train struck another freight train as it rolled through a small village in southeastern Wisconsin, causing cars to derail, injuring two people and spilling thousands of gallons of fuel that prompted the evacuation of dozens of homes.

The southbound Canadian National train struck several Wisconsin & Southern Railroad cars around 8:30 p.m. Sunday at a rail crossing in Slinger, according to Patrick Waldron, a Canadian National spokesman.

Three engines and 10 railcars derailed, Slinger Fire Chief Rick Hanke said. Slinger is about 35 miles northwest of Milwaukee.

An engineer and conductor on the Canadian National train were taken to a hospital, treated for injuries and released, Waldron said Monday.

About 5,000 gallons of diesel spilled from a locomotive fuel tank, Hanke said. Hazardous materials crews placed booms around the spilled fuel and crews worked to upright the derailed cars Monday morning.

Some 100 people who live near the crash site were evacuated from their homes as a precaution but they were allowed to return around 1:30 a.m. Monday, Hanke said.

The Wisconsin & Southern engineer applied the brakes after an onboard computer sensed something was wrong before the collision, said WSR spokesman Ken Lucht.

“There was an emergency situation prior to impact,” Lucht said.

Investigators will interview the crew members and inspect both trains to determine what specifically triggered the sensor, he said.

The Wisconsin & Southern train was headed northbound from Janesville to Horicon, and was carrying lumber, steel and plastic pellets, Lucht said. Some of the lumber spilled from a rail car. The Canadian National train was southbound from Fond du Lac to Champaign, Illinois, and was carrying sand, Waldron said.