RIO DE JANEIRO -- A raid of Rio de Janeiro's largest complex of favelas that left at least 18 people dead has sparked renewed complaints of excessive police violence and ignited debate over how to handle crime ahead of state and presidential elections.

Rio authorities said 16 suspected criminals were killed in confrontations with police in Complexo do Alemao favela, or low-income community, along with a police officer and an woman. The raid targeted a criminal group that stole cars and robbed banks, and invaded nearby neighbourhoods.

Videos circulating on social media showed intense shootouts between criminals as well as a police helicopter flying low over the small, brick houses. Rio's police have used helicopters to shoot at targets, even in densely populated residential areas, and video showed shots being fired from the favela at the aircraft.

At the site of the raid, Associated Press reporters saw residents carrying about 10 bodies as bystanders shouted, "We want peace!"

"It's a massacre inside, which police are calling an operation," one woman told AP, speaking on the condition of anonymity because she feared reprisals from authorities. "They're not letting us help (victims)," she added, saying she saw one man arrested for attempting to do so.

Ronaldo Oliveira, an investigator with Rio's police force, said officials would have rather just made arrests of suspects "but unfortunately they chose to fire at our policemen."

Rio state Gov. Claudio Castro, who is running for reelection in October, said on Twitter he lamented the police officer's death.

"I will continue to fight crime with all my strength. We will not back down from the mission of guaranteeing peace and security to the people of our state," Castro said.

In another tweet, Castro said his main rival in the elections, leftist Marcelo Freixo, defends criminals who attack police, "such an important institution that makes us so proud." Freixo responded that the governor "uses police to make politics."

The government's strategy for tackling violence and organized crime, an approach that regularly sees deadly police operations, has come under criticism. A raid in Rio's Vila Cruzeiro favela in May killed more than 20 people.

Brazil will also hold presidential elections in October with security a key issue and President Jair Bolsonaro touting a tough-on-crime approach.

"ENOUGH of this genocidal policy, governor!" Taliria Petrone, a federal lawmaker for Rio, said in response to the governor's tweet. "This failed public security policy leaves residents and police on the ground, en masse. It's no longer possible to keep piling up Black bodies and favela residents every day!"

Robert Muggah, co-founder of Igarape Institute, a Rio de Janeiro-based think tank focused on security, said Thursday's raid is "a symptom of failed leadership and an institutional culture that condones excessive force."

"The killings resulting from large scale police operations is a grim reminder that militarized policing is not only ineffective, it is counterproductive," Muggah said in a text message, adding those raids generate "extreme violence predominantly affecting low-income Black populations while also corroding the trust between residents and law enforcement."

Alemao is a complex of 13 favelas in northern Rio, home to about 70,000 people. Nearly three-quarters of them at Black or biracial, according to a July 2020 study published by the Brazilian Institute of Social and Economical Analyses.

Earlier this year, Brazil's Supreme Court established a series of conditions for police to conduct raids in Rio's favelas as a means to reduce police killings and human rights violations. The court ordered that lethal force be used only in situations in which all other means have been exhausted and when necessary to protect life.

The ruling came in response to a raid on the Jacarezinho favela in 2021 that resulted in 28 people being killed. As was the case Thursday, an officer died during that raid, which some speculated at the time was the cause for subsequent abuse and summary executions.

Thursday's operation began before dawn and finished around 4 p.m. local time, police said. Nearly 400 police officers were involved, including Rio's tactical police unit, according to the police statement.

In a video shared by Voz da Comunidade, a community news outlet focused on Rio's favelas, residents can be seen calling for peace and waving white cloths from their windows and rooftops.

Fabricio Oliveira, one of the coordinators of the police raid, said authorities fear that Friday could be another violent day at the Complexo do Alemao.

"Our experience has told us that after raids like these police are attacked in every way," Oliveira said.

Human rights group Amnesty International said on Twitter that prosecutors must immediately investigate policemen involved in Thursday's raid.

"WHO WILL STOP Gov. Claudio Castro and his disastrous and rights violating public security policies in Rio de Janeiro," the non-profit said. "Enough of so much brutality! THE FAVELA WANTS TO LIVE!"

--------

AP journalist Mauricio Savarese contributed to this report from Sao Paulo