FRESNO, Calif. (KSEE/KGPE) – The Fresno Police Department has released body camera footage of officers opening fire on a suspect accused of stabbing a K-9 deputy in January.

On January 2, officers said they received information on the whereabouts of 27-year-old Gabriel Mata, a known gang member who was wanted for a felony domestic violence charge. Investigators said Mata had also threatened to shoot the victim and police officers.

When officers arrived at the home near Maple and American avenues, they reported that Mata had run into a nearby field.

WARNING: This body camera video provided by the Fresno Police Department is violent and may contain foul language.

Officers and deputies from the Fresno County Sheriff’s Office worked to get Mata to surrender peacefully and called in K-9 Deputy Cyra to help take him into custody. Investigators said they tried several times to get Mata to surrender, but he continued to refuse.

Image of K-9 officer Cyra provided by the Fresno County Sheriff’s Office

After the failed negotiations, the K-9 Cyra was let loose to help capture Mata.

While approaching Mata, two officers said they saw him repeatedly stabbing the K-9 deputy.

Officials said both officers fired their guns, striking Mata at least one time.

K-9 Cyra survived her injuries and was taken to a nearby emergency veterinarian for treatment. Mata was taken to a local hospital, where he survived his injuries.

“Peace officers will always attempt to gain voluntary compliance first, as it is the safest tactic for everyone involved,” Fresno Police Chief Paco Balderrama said in a statement about the shooting. “At times, even the most reasonable attempts will fail, and force must be used. This is one of those cases.”

Mata was later booked into the Fresno County Jail on felony domestic violence charges.