Then-Baltimore Police Commissioner Kevin Davis speaks at a news conference in Baltimore on Nov. 16. (Patrick Semansky/AP)

Baltimore’s mayor on Friday abruptly replaced Police Commissioner Kevin Davis weeks after the city ended 2017 with a record-setting homicide rate and amid increased political pressure to control crime.

Mayor Catherine E. Pugh named a deputy commissioner, Darryl D. DeSousa, a homegrown veteran who over 30 years rose through the ranks, as interim leader of the beleaguered police force of about 2,300.

The leadership change comes as Davis was overseeing the department during one of its most difficult eras. He was tasked with driving down violent crime that flared to historic levels after a young man’s death in police custody while simultaneously reforming an agency the Justice Department cited for discriminating against black residents. In his last year, Davis had to reckon with the federal indictment of several officers from an elite unit accused of shaking down drug dealers and frustration over the recent unsolved killing of a city homicide detective.

“We need violence reduction,” Pugh said Friday at a news conference, less than a month after she had told that city crime had begun to trend down in the most dangerous neighborhoods. “We need the numbers to go down faster than they are.”

DeSousa, a New York native who joined the Baltimore police force in 1988, pledged to stem the bloodshed through “real, active, constitutional policing” and immediately sent an extra contingent of uniformed officers to the streets.

The city of Baltimore is ending 2017 with more than 300 homicides, making it one of the deadliest cities in the U.S. (Claritza Jimenez/The Washington Post)

He said the extra officers are being sent to troubled areas and streets with specific orders to focus on “trigger-pullers” and even merchants who help in the drug trade.

“We are moving at an accelerated pace,” DeSousa, 53, said of targeting gunmen in the city. “The district commanders know who they are, and we’re coming after them. . . . The citizens of Baltimore will see us getting ahead of crime.”

Friday’s promises to mend a fractured city and crack down on crime with a change in leadership echoed many of the hopes expressed two and a half years ago, when Davis took over the department after the removal of Anthony W. Batts, who had also been replaced amid concerns over rising crime rates.

Davis became commissioner in 2015 in the aftermath of rioting that followed the death that year of Freddie Gray from an injury in police custody.

The department’s tactics drew federal scrutiny after Gray’s death and resulted in a consent decree with the Justice Department requiring reform.

Davis was left to balance trying to change a culture of policing the Justice Department calleddiscriminatory while being tough enough on criminals to deliver safe streets.

Officers were not as aggressive as they might ordinarily have been out of fear “they, too, would be arrested for doing their jobs,” said Gene Ryan, a Baltimore police lieutenant who heads the Fraternal Order of Police labor union.

Chuck Wexler, executive director of the Police Executive Research Forum, said the average tenure of a police chief is three or four years but that Davis was “really between a rock and a hard place in trying to implement reform and deal with violent crime.”

“It’s almost like changing two tires on a car at the same time,” Wexler said.

Davis could not be reached to comment.

Some Baltimore residents dismissed Davis’s ouster as a political move, saying the churn of police leadership won’t address systemic problems that drive violence. DeSousa will be the city’s ninth police commissioner in 20 years.

Warren A. Brown, a Baltimore defense attorney who has practiced in the city for 40 years, said the city is stricken by “poverty, lead-paint poisoning, despair and the proliferation of handguns.”

“The root is so rotten, it doesn’t even matter who’s at the top,” Brown said. “Rather than deal with this rot, this is a quick fix.”

Pugh has been under intense pressure to lower the crime rate after a year of sobering headlines.

Baltimore finished 2017 with a record-setting 343 homicides, making it one of the deadliest cities in the country.

Members of Baltimore’s City Council and police union leaders criticized Pugh for failing to put forward a clear and comprehensive crime plan for the city. When Pugh appeared on a local radio station, a host demanded that she explain why residents should not move to the suburbs “as fast as possible.” The 98 Rock host told her, “This city is slipping away.”

Last year’s killings in Baltimore included several high school students, victims of random robberies and the bludgeoning death of a 97-year-old man in his home. Two high-profile slayings that remain unsolved are those of a Baltimore homicide detective as he worked a case and of an off-duty D.C. police sergeant fatally shot in his car.

Pugh wrote a column that appeared last week in The Washington Post in which she described the end of 2017 as one of a “sense of loss, regret and deep frustration.” She wrote of a young college student killed after he innocently came by a robbery in progress.

“These sad realities are legitimately part of our narrative,” Pugh wrote. “But we are working hard to write a new narrative, one that reflects our progress and determination to end violence by ending the conditions that are its undeniable cause. ”

While Davis was sometimes criticized as being too oriented toward community-policing, he spent much of his early tenure trying to prevent a second riot after the verdicts came in for officers charged in the Gray case. He sought to restore community trust in the police after none of the officers charged in the Gray case were convicted.

In an HBO documentary, “Baltimore Rising,” which aired in November and chronicled activists and others in the aftermath of the unrest, Davis was seen playing football with residents and told a former gang member, “I’m sorry that law enforcement in this community is like this.”

Brown said it appeared that Davis made visible efforts to understand Baltimore’s inner workings despite coming to the department as an outsider, having risen through the ranks in Prince George’s County and serving briefly as chief in Anne Arundel County.

“He put his heart into it, and he was sincere about trying to make a change to reduce violence,” Brown said.

But some in the community remained unsatisfied, and in the last months of 2017, Pugh continually declared that crime in the city was “out of control.”

Ryan, the head of the police union and a 35-year-veteran, said he looks forward to DeSousa as “a fresh start.”

DeSousa, who grew up with the department, is more suited to understanding the city, Ryan said. The challenge will be finding the “happy medium” between tough and fair policing. Officers, he said, “want the city to succeed.”

Cameron Miles, who has run a program called Mentoring Male Teens in the Hood since 1996, said young men in the city still have a deep distrust of the police.

“Some of them are made to sit on the curbs with their pockets turned inside out when they’re suspected of something,” Miles said. “I hope the new leader will implement workshops and training that will foster mutual respect. That will go a long way in helping the community to better respect the police and ultimately have them willing to help the police.”

On Friday, DeSousa, like other new commissioners before him, vowed to bring change.

“A lot of lives were lost” and there’s “a lot of people with bleeding hearts,” DeSousa said. “There’s a lot of work that needs to be done.”