Kim Hjelmgaard

USA TODAY

BERLIN — Two commuter trains collided head-on Tuesday after an automatic braking system apparently failed on a curve, killing 11 people and injuring 80, officials said.

The impact tore the two engines apart, shredded some train cars and flipped several of them on their sides, aerial footage showed.

The regional trains crashed before 7 a.m. local time in the southern state of Bavaria, near the town of Bad Aibling, about 40 miles southeast of Munich.

“This is the biggest accident we have had in years in this region,” police spokesman Stefan Sonntag said, the Associated Press reported.

German rail operator Deutsche Bahn said safety systems on the stretch had been checked as recently as last week.

Transport Minister Alexander Dobrindt suggested that a system designed to automatically brake trains if they accidentally end up on the same track didn’t seem to have functioned properly, the AP said. Dobrindt said it was too early to draw a definitive conclusion.

"As the collision occurred on a bend, it's conceivable that the two train drivers didn't see each other beforehand," Dobrindt said at a news conference. He said speeds up to 60 mph were possible on that stretch.

Black boxes from both trains were recovered and were being analyzed to help learn what went wrong, Dobrindt said. “We need to determine immediately whether it was a technical problem or a human mistake,” he said.

Police said everyone on the train was pulled from the wreckage amid a chaotic and difficult effort to reach the crash scene. The crash occurred near a river that is surrounded by dense woodlands and uneven terrain, the German news agency DPA said. Several dozen people were seriously injured. Helicopters and several ambulances responded to the accident.

The train line was often used by commuters and schoolchildren, but it was less busy than usual because schools in the area were on vacation for the carnival holiday.

Serious train accidents are relatively rare in Germany. One of the worst incidents, not just in Germany but also worldwide, took place in 1998 when a high-speed train derailed near the village of Eschede, killing 109 people, according to DPA.