(CNN) - At least 57 people were killed, including 16 who were decapitated, during a vicious gang battle that erupted in a prison in northern Brazil on Monday morning.
The unrest is reported to have begun when a local gang stormed a wing of the facility in Para state controlled by a rival group, state news reported. The majority of the victims are believed to have died from asphyxiation, after gang members set fire to part of the prison complex.
State media said the violence began around 7 a.m., local time in the Regional Recovery Center in the city of Altamira and lasted for several hours. Video of the scene showed prisoners sat on the roof of the building, brandishing knifes and with their heads covered, amid smoke rising from the interior.
Two correctional guards taken captive were released, state media reported.
Ten of the 16 prisoners who were blamed for instigating the violence will be transferred to federal penitentiaries, state media reported, citing local authorities. More than 46 other prisoners will be moved to other prisons in Para.
The incident is the latest outbreak of deadly violence in recent months to have taken place in Brazil's often overcrowded and underfunded prison system.
In May, 55 inmates were killed in gang-related riots at four prisons in western Brazil.
The local prison authorities said at the time the deaths were a result of violent clashes among rival factions within the same drug gang, known as the Family of the North.
Benjamin Lessing, a professor at the University of Chicago who studies Brazil's prison gangs, said that there were likely local factors at play in Monday's violence, but the attacks were also part of an ongoing turf war between the country's two main gangs and a "whole constellation of local gangs."
"Most of the violence has been in this region, the north and the northeast region, and it's a place where these gangs are actively fighting each other to achieve some kind of local hegemony or at least carve out space," Lessing said.
"It doesn't mean these gangs don't exist in the rest of Brazil -- they do, and there's violence in other parts of Brazil too related to these gangs. But it seems like where the fighting is very intense right now is in this north-northeast region."
The gangs used to only exist in Rio de Janeiro, but in recent decades have spread throughout the country, Lessing said.
In turn, the country's prison population has ballooned to the world's third-largest, trailing only the United States and China, according to the World Prison Brief.
Brazil's penitentiary system has for years been plagued by violence due to what analysts have described as systemic failures. The country's top prison official resigned in 2017 after a series of problems with drugs, corruption, escapes and riots.
Human rights groups have accused the government of doing too little to prevent the violence at prisons that have become recruitment centers for gangs -- and even facilitating clashes by allowing the cells to become overcrowded.
"As you start to lock up more and more people, you're really giving fuel to the fire. You're putting more people in the hands of these prison gangs, giving them more power to recruit," Lessing said.
Monday's clashes pose a challenge to the country's new far-right President Jair Bolsonaro, who has previously vowed to crack down on criminal gangs and prison violence.
CNN's Flora Charner and Joshua Berlinger contributed to this report