Of course, all that goes away in the case of subsonic rounds. Then your only real difference is that a gun propellant is going to have a much faster velocity than the gunpowder in fireworks and the explosion is going to be rather better contained. You'll probably still be able to differentiate, but I'm not sure how effectively, especially over long distances.
I'm pretty sure that presents a problem. Many handgun rounds have subsonic muzzle velocities, and most are subsonic within 50 feet. And according to the FBI's Uniform Crime Reports[1], almost half of all murders are committed with handguns. Rifles are used in around 2-3%. (For comparison, 5-6% of murders are committed with bare hands.) Those numbers underestimate the ratio of rounds fired by handguns vs rifles, as being shot with a rifle is far more likely to result in death than being shot with a handgun. If the victim doesn't die, they won't show up in those FBI stats.
1. FBI Uniform Crime Report on murder weapon type: https://www.fbi.gov/about-us/cjis/ucr/crime-in-the-u.s/2013/...
It's all about having a large enough corpus of input, both of the type you're looking for and the type you're looking to exclude. This is an undergraduate level problem to solve.
The most important difference here is a gun is pushing a projectile out and a car isn't.
Differentiating between cap guns, starter pistols and fireworks might be a little more hazy, but it's still not the same thing as a backfiring car.
Yet another company spamming for yet another surveillance device.
tl;dr Statistically acceptable and verifiable measures(homicides, suicides, gunshot injuries) of gun violence are not shocking enough - we should replace them with counts of every potential gun shot fired.
"potential gun shot" = e.g., truck backfiring, dumpster lid dropping, slamming door, car collision, gunshot, etc.
Any stats available on how many "loud bangs" occur in a city each day?