A detective with the NYPD's Special Victim's Unit shot and wounded a man who allegedly pointed a gun at him and his partner in East Harlem last night. According to the NYPD, the two plainclothes detectives were in the vicinity of East 101st Street and First Avenue around 8 p.m. yesterday when they saw a man running south on First Avenue with a gun in his hand.

Police say the gunman, identified by police as Wilvinson Diaz, 26, was seen opening fire on a 21-year-old man who was walking away from Diaz. The victim was shot in the torso and leg, but fled north on First Avenue, according to investigators. Diaz was chasing him when the detectives say they identified themselves as officers and ordered him to drop the weapon. Instead, Diaz allegedly pointed his gun at the detectives.

One of the detectives (whom the NYPD has not named) fired two rounds at Diaz, hitting him in the torso. EMS responding to the scene took him to Harlem Hospital in stable condition. Police say the 21-year-old victim went to Metropolitan Hospital "by private means," where he is also listed in stable condition. (The NY Post, which identifies the victim as Rajeev Gobia, reports that he "hopped into a car and fled, but later went to Metropolitan Hospital on his own.") The detectives were treated for tinnitus.

“I was eating dinner and I heard two things that sounded like firecrackers and then I heard a big boom," one elderly man who lives nearby tells the Daily News. "So two shots that sounded like a .22 and two shots that sounded like a Glock, like what a police officer would use."

Diaz has been charged with Attempted Murder, Felony Assault, Criminal Possession of a Loaded Firearm, Criminal Use of a Firearm, Reckless Endangerment and Unlawful Possession of Marijuana.