Officials conduct an investigation at the scene of a police-involved shooting in Baltimore on March 31, 2016. (Patrick Semansky/AP)

A father and son armed with a pistol and a semiautomatic rifle appeared ready to open fire on other people Thursday when they were killed by two police officers, who fired 56 rounds during the late-afternoon encounter in an East Baltimore neighborhood, police said.

Police Commissioner Kevin Davis said Friday that officers on patrol watched Matthew V. Wood Jr., 43, and his son, Kimani Johnson, 18, pull up on East Lanvale Street near Green Mount Cemetery about 4 p.m. and emerge from a vehicle holding weapons.

Officials said police thought the men were poised to shoot at a group of people on the other side of the street.

“If not for the Baltimore Police Department yesterday, we could have had a mass shooting on our hands, where several innocent lives could have easily been taken,” Davis said at a news conference at police headquarters.

Neither Wood nor Johnson fired, Davis said, but he commended the officers for preventing them from shooting. At the news conference, police displayed a large pink rifle they say Wood was carrying.

“We don’t run from bad guys with guns. We engage them,” Davis said. “We fired 56 rounds yesterday until this threat was eliminated.”

Two law enforcement sources said investigators think Wood and Johnson were affiliated with the Black Guerrilla Family gang, which is believed to be causing much of the violence in some city neighborhoods.

A convicted member of the gang was fatally shot Wednesday night in the Barclay neighborhood, a few blocks north of Thursday’s shooting in Greenmount West.

The gunfire by police happened steps away from a playground asneighborhood residents were returning from work.

More than 150 people have been shot in the city this year, with homicides up 11 percent compared with the same period last year and nonfatal shootings up 49 percent. Last year saw the highest per-capita homicide rate in the city’s history, kick-started by a surge in violence after the death of Freddie Gray in April.

Johnson was free on $100,000 bail awaiting trial for a handgun charge, court records show. Wood, meanwhile, was on probation after receiving a sentence of time served — about three months — in October for a gun charge.

The charge to which Wood pleaded guilty should have brought a mandatory sentence of five years in prison without parole, but Judge Alfred Nance of the Baltimore City Circuit Court said prosecutors agreed to “step off” that requirement, according to a recording of Wood’s plea hearing.

Police identified the officers as Norman Jones, who has been on the force for two years, and Sgt. Joseph Wiczulis, who has eight years’ service.

Wiczulis has been involved in two previous shootings since 2010. In one he shot a man who had shot two officers.

Jones, Wiczulis and a third officer, who did not fire, are on routine administrative leave. The prosecutor’s office declined comment on its investigation.

Davis said the officers were in civilian clothes with vests that identified them as police.

The commissioner said the officers happened to be riding by when they came upon the two armed men. He said the team had been patrolling the area in an unmarked car as part of a broader crime-fighting effort in the community.

“They rode by this car. You can just imagine, they’re driving by this Volvo that just parked on the side of the road and out pops two . . . gunmen. One with a long gun; one’s got a pistol,” Davis said.

It is unclear how many people the men were thought to be targeting, but Davis said Wood and Johnson were moving toward a group of people across the street. The rifle was loaded to capacity with 25 rounds and the handgun had seven rounds, police said.

Before the officers opened fire, Davis said, Wood and Johnson said “something threatening” to the group across the street, witnesses told police.

A woman who identified herself as Johnson’s mother, declined comment on the shooting, but called him “the first true love of my life.” She said he was to turn 19 on Monday.

Wood’s gun arrest in October came after police said they saw him dealing drugs outside his home and later found a pistol in his home.In 1996, he pleaded guilty and received probation on a handgun charge.

The head of the police Office of Professional Responsibility said “a number of civilian witnesses” corroborated statements from the witness officer.

— Baltimore Sun

Sun reporter Yvonne Wenger contributed to this report.