Precision and accuracy of acoustic location in an urban environment

Robert B. Calhoun,1, a) Clark Dunson,1 Murphey L. Johnson,1 Scott R. Lamkin,1 William R. Lewis,1 Robert L. Showen,1 Mark A. Sompel,1 and Lester P. Wollman1 ShotSpotter, Inc., Newark, CA 94560, USA The caused by the discharge of a firearm generates a loud, impulsive that propagates away from the shooter in all directions. The location of the source can be computed from time-of-arrival measurements of the muzzle blast on multiple acoustic sensors at known locations, a technique known as multilateration. The multilateration problem is considerably simplified by assuming straight-line propagation in a homogeneous medium, a model for which there are multiple published solutions. Live-fire tests of the ShotSpotter gunshot location system in Pittsburgh, PA were analyzed off-line under several algorithms and geometric constraints to evaluate the accuracy of acoustic multilateration in a forensic context. Best results were obtained using the algorithm due to Mathias, Leonari and Galati under a two-dimensional geometric constraint. Multilateration on random subsets of the participating sensor array show that 96% of shots can be located to an accuracy of 15 m or better when six or more sensors participate in the solution. c 2020 ShotSpotter, Inc. [http://dx.doi.org(DOI number)]

[XYZ] Pages:1–18

PACS numbers: 43.60.Jn, 43.28.-g, 43.28.Bj

I. INTRODUCTION acoustic multilateration, and quantifies the precision and accuracy of the results obtained using data collected un- The muzzle blast resulting from discharge of a der controlled but realistic conditions. firearm generates a loud, impulsive noise that propagates The data derive from a series of live fire tests of the away from the shooter in all directions. The location of ShotSpotter gunshot location system conducted in Pitts- the shooter can be estimated by minimizing the differ- burgh, PA. These tests were analyzed offline to identify ence between the measured and predicted arrival time of the combination of algorithm and geometric constraint the muzzle blast on multiple time-synchronized sensors, that offers the greatest precision when locating a technique known as acoustic multilateration. Public in a forensic context. Pittsburgh was selected as a study safety agencies use networks of acoustic sensors to locate area for a number of reasons: first, a large number of tests illegal gunfire in near real-time, 10–15 seconds after dis- were conducted (three firearms discharged from nine fir- et al. charge (Aguilar, 2015; Lawrence , 2018; National ing positions) covering neighborhoods with a density of Law Enforcement and Corrections Technology Center, structures similar to that of many ShotSpotter coverage et al. 2007; Watkins , 2002). areas; second, the hilly terrain offered the opportunity Acoustic data are also used in forensic context (Beck, to investigate the importance of locating in three dimen- et al. 2019; Begault , 2019; Brustad and Freytag, 2005; sions; and finally because the Pittsburgh array features Maher and Hoerr, 2018; Maher and Routh, 2015). Acous- an unusually high sensor density, allowing for simulation tic multilateration cannot identify a shooter, but it can of the effects of deployed sensor density on detection rates establish the discharge location and discharge time for and location accuracy. each individual shot fired in a repeatable and objective Source data from the Pittsburgh tests comparable manner. The efficacy and accuracy of an acoustic mul- to what is submitted as evidence in a criminal trial are tilateration system depends on the number and position provided as supplemental materials. These materials of reporting sensors, the accuracy to which the initial ar- comprise time-stamped acoustic recordings, time- and rival time can be measured, and the validity of the prop- location-stamped output of the pulse processing algo- agation model, with the simplest acoustic propagation rithms, and tagged pulse sets suitable for acoustic mul- model assuming straight-line propagation. The present tilateration. These data permit other investigators to work outlines a procedure for computing shot locations review or extend the current work. from acoustic measurements of the muzzle blast using

a)[email protected]

ShotSpotter Tech Note 098 / 14 January 2020 Accuracy of acoustic gunshot location 1 II. THEORY OF GUNSHOT LOCATION nal; only pulses from “near line-of-sight” paths pass the mutual consistency test. This principle is illustrated in A. Source signal Figure2, which shows the envelopes of three successive The muzzle blast of a gunshot is an impulsive acous- shots detected on five different sensors. Strong echoes tic source that emits power over a broad range of frequen- are detected on three of the sensors, but only the initial cies. (Weber, 1939) developed an expression for the pres- impulse from each shot is consistent with a straight-line sure of spark explosions that has applicability to muzzle propagation model on all the fives sensors. The mutual blasts; the resulting expression is similar to that intro- consistency method can only be used when the number of duced by (Friedlander, 1946). The single parameter of reporting sensors exceeds the minimum number of time the Weber model is the Weber radius rw, the radius at differences of arrival (TDoAs) required for multilatera- which the supersonic combustion products decelerate to tion. The method works best when the sensor density is sonic velocity. Unlike explosions, muzzle blasts are highly high enough to ensure gunshots are detected on at least directional (Beck et al., 2011; Maher and Shaw, 2010) but two more sensors than required for multilateration, but they can be modeled as a Weber source in which the size not so high that the system generates false triggers on of rw depends on the angle between the barrel and unwanted sources of impulsive noise such as construction the receiver (Hirsch and Bertels, 2013). noise. Muzzle blasts are simple impulses (Maher, 2009) and 0.5 recordings made in open environments (such as Kruger 473 m National Park in South Africa, Figure1, top) show rea- 0.0 sonable agreement with simple models (Don and Cra- mond, 1987; Embleton, 1996). In built-up areas, propa- -0.5 gation distances are shorter and the received waveforms 0.5 443 m are more complicated (Figure1, bottom.) (Hornikx, 2016) notes that “ levels in urban areas 0.0 depend at one hand on the actual sound sources, and at -0.5 the other hand on the propagation of sound from these 0 0.02 0.04 0.06 0.08 0.1 0.12 0.14 0.16 0.18 0.2 sources in the environment”, a statement that is particu- time, s larly applicable to urban gunshots, where a simple source signal becomes a complicated received signal as a result FIG. 1. discharged at similar ranges in an open of the environment. In urban environments the acoustic environment (top: Kruger National Park, South Africa) and energy of the muzzle blast is transferred from source to in an urban environment (bottom: city in the midwestern a receiver via many different paths, including specular United States); the vertical scale is with respect to ADC full and diffuse reflection (echoes and reverberation), diffrac- scale of 93 dB SPL = 1.0. tion (transmission around structures), refraction (bend- ing due to speed-of-sound gradient), as attenuated by absorption in the atmosphere and at surfaces (Kapra- los et al., 2008). It is possible to model acoustic propa- gation in an urban environment using ray-tracing and B. Pulse localization other computational modeling techniques (Albert and In built environments, the acoustic energy from a Liu, 2010; Le Bot and Bocquillet, 2000; Mehra et al., muzzle blast arrives via multiple paths. Energy transmit- 2014; Parker et al., 2007; Pasareanu et al., 2018; Remil- ted via the shortest acoustic path arrives first; additional lieux et al., 2012; Stevens and Murphy, 2014) but these energy from the blast is delivered via reflections and other models require a structural model of the area and are in indirect paths over a period of time that may extend to some cases computationally demanding. several seconds. In the present work, signal refers to the A simpler approach (Showen, 1997; Showen et al., acoustic pressure change induced by the muzzle blast as 2008) is to deploy more than the minimum number of sen- measured by a remote as a function of time; sors required for multilateration and assume a sufficient the goal of the pulse detection algorithm is to identify number of sensors will receive detectable levels of muzzle the arrival time of pulses—fast rise time portions of the blast energy via paths well-approximated by a straight- measured signal—that are plausibly due to muzzle blast line propagation model. These “near line-of-sight” pulses energy arriving via the shortest acoustic path. Because can be identified by constructing sets of pulses from ap- shortest acoustic paths are often not line-of-sight paths, propriate sensors, computing a prospective location from significant attenuation may occur and the acceptance cri- the pulse set, and comparing arrival time predictions of teria for muzzle blast impulses must necessarily be broad. the model with the measured arrival time on each sensor. One effective strategy for detecting plausible muzzle The goal of this combinatorial optimization problem is to blasts in built environments is to convolve the envelope find the largest set of pulses that meet a mutual consis- of an acoustic signal with a step-detection kernel. This tency test. Specular reflections (echoes) are rejected be- acknowledges that muzzle blast power will be broadly cause the path between source and each sensor is distinct, distributed in the time domain, while giving the most resulting in different echo patterns in each received sig- weight to the earliest-arriving signal.

2 ShotSpotter Tech Note 098 / 14 January 2020 Accuracy of acoustic gunshot location 1.0 g 79 m The kernel gives as much weight to the absence of signal prior to pulse arrival as it does to the amplitude of 0.5 the signal that follows; this provides consistent estimates

0.0 of the arrival time of the most direct (earliest-arriving) path, even when the energy received via that path is a 1.0 223 m small fraction of the total. Increasing the length scale τ 0.5 reduces spurious triggering on echoes and reverberation, but an excessively long window reduces the ability to de- 0.0 tect closely-spaced shots. Empirically, a value of 50 ms 1.0 350 m has been found to work well on both isolated shots and the range of semi-automatic (300 rpm) and fully auto- 0.5 matic (450–950 rpm) firearms encountered in a public-

0.0 safety context. Note this is 10–20 times the duration of et al. 1.0 a muzzle blast measured on an open range (Beck , 474 m 2011; Maher, 2011; Routh and Maher, 2016), which is on 0.5 the order of 2 ms.

0.0 1.0 223 m 1.0 775 m 0.8 0.6 0.5 0.4 0.0 0.2 0.0 0.2 0.4 0.6 0.8 1.0 1.2 1.4 1.6 1.8 2.0 0.0 time, s -0.2 -0.4 -0.6 FIG. 2. Waveform envelopes for a sequence of 3 rounds from -0.8 a 9mm pistol as recorded by sensors at 79 m, 223 m, 350 m, -1.0 0.495 0.496 0.497 0.498 0.499 0.500 0.501 0.502 0.503 0.504 0.505 474 m and 775 m showing that range alone is not a good pre- time, s dictor of signal strength. Echo patterns vary from location to location, allowing the near line-of-sight paths to be identified FIG. 3. Pulse arrival time (red dot) plotted on the original through their greater self-consistency. The signals have been waveform for sensor at 223 m distance from Figure2. Dotted aligned in the time domain; the vertical scale is the same for line shows output of pulse localization function x(t) from (2). all plots, with amplitude of 1.0 corresponding to ADC full The full scale amplitude approximately 93 dB SPL. scale of 93 dB SPL.

Let f(t) be the amplitude of an acoustic signal as a function of time t. The instantaneous magnitude (or C. Pulse Selection envelope) of f(t) is given by the magnitude of the analytic associate of f(t) In urban environments, true line-of-sight paths are rare. “Near line-of-sight” paths, where the received sig- kfk = kf(t) + iH(f(t))k nal is line-of-sight after a single diffraction over a barrier, where H(f(t)) is the Hilbert transform of f(t)(Boashash, can be used for location because the typical height of 2015). Define a weighted step-detection kernel g(t) as buildings is small compared with the distances between  acoustic sensors. Use of non-line of sight paths with sig- t/τ + 1 for − τ < t ≤ 0  nificant time delays, such as those generated by specular g(t) = −1/2 for 0 < t ≤ τ (1) reflections from buildings and other hard surfaces, will 0 otherwise cause significant location error if used in a multilatera- tion calculation. Associating pulses from one shot with where τ is a length scale over which the signal should be pulses from a different shot will also result in large mul- averaged. tilateration error. Define x(t) as the convolution the signal envelope The construction of sets of pulses that are appropri- kf(t)k and kernel g(t): ate for multilateration becomes more difficult as the num- ber of shots and number of shooters increases. ShotSpot- x(t) = (kfk ∗ g)(t). (2) ter’s pulse selection algorithms use a combination of com- The pulse arrival time is defined as the time t at which binatorial optimization, pattern-matching and numerical x(t) is locally maximized. Pulses with values of x(t) that optimization methods to search for the largest possible fall below a threshold are discarded. set of mutually-consistent pulses for each shot. The se-

ShotSpotter Tech Note 098 / 14 January 2020 Accuracy of acoustic gunshot location 3 lection of appropriate pulses for multilateration is an in- volved topic (Beck, 2019; Calhoun, 2011; Showen et al., 2008) and a full discussion of the methods used is out- side the scope of the present work. To facilitate review of the present multilateration results, the output of the ShotSpotter pulse selection routines (comprising sets of acceptably “near line of sight” pulses for each shot) are provided as part of the supplemental materials, along with sufficient audio data to verify that the selected pulses are associated with the shortest acoustic path1. Because the search for pulse sets is not exhaustive, the tuples provided are not guaranteed to be an optimal sub- 1400 m set for each test. However, all pulses in a tuple will have an error of less than 40 ms between the measured arrival time and the predictions of a straight-line propagation model.

D. Source Localization Acoustic multilateration, the location of a source 1400 m from multiple time difference of arrivals (TDoAs), has been in use since World War I when French (Aubin and FIG. 4. Graphical representation of the intersecting hyper- Goldstein, 2014), Canadian (Finan and Hurley, 1997) bola approach characteristic of Reddi algorithm. The refer- and British forces (Van der Kloot, 2005) used sound rang- ence sensor that defines the time differences of arrival is the ing to locate the source of fire. Many multilater- first reporting sensor. The sample data is from test 1 at Firing ation algorithms have been documented since that time. Position 4. A multilateration solution in d dimensions requires at least n = d + 1 reporting sensors. Some n = d + 1 solutions have two mathematically consistent solutions. for i = (1, 2, . . . n) where Additional methods not discussed in the present work, such as measurements of angle-of-arrival (AoA) or re- ceived signal power, are required to resolve ambiguous solutions, so the present work focuses on solutions for 2 2 2 2 Si = (x − xi) + (y − yi) + (z − zi) . which n ≥ d + 2, for which the multilateration solution is always unique given non-degenerate sensor placement. The TDoA source location problem reduces to find- ing the point of intersection of multiple hyperboloids, so This reduces to a quadratic equation that can be solved the algorithms comprise variations on a common theme. for source location (x∗, y∗, z∗). Discharge time t∗ is ob- ShotSpotter uses multiple algorithms because they ex- tained from the mean value of ti − Si/c at (x∗, y∗, z∗). hibit different numerical stability and sensitivity to the This implementation requires a minimum of d+1 TDoAs, choice of a reference sensor. Below we analyze the ac- where d is the number of dimensions. curacy of four algorithms and three constraints under a variety of array densities to compare their relative per- 2. MLG formance under real-world test conditions. A goal of the present work is to identify which algorithm is best-suited (Mathias et al., 2008) avoid use of a reference sen- for forensic work. All solutions discussed assume line-of- sor by minimizing the squared error on each sensor. sight propagation in a homogeneous, stationary medium. ShotSpotter’s “MLG” implementation slightly modifies this algorithm by solving for time-distance (ct) instead 1. Reddi of t, which improves computational stability. For the simplified case of overdetermined systems (n > d + 1) This implementation is based on (Reddi, 1993). with receiver matrix With reference sensor at (0, 0, 0) and other sensors at (xi, yi, zi), i = 1, 2, 3, . . . n, source location (x∗, y∗, z∗) can be found from relative arrival times ti by equating   the squared distance from the reference to the source with x0 x1 . . . xi the square distance of the reference to the other sensors:  y y . . . y   0 1 i    R =  z0 z1 . . . zi  , (4)   −ct0 −ct1 ... −cti  p 2 2 2 cti = Si − x + y + z (3) −c/2 −c/2 ... −c/2

4 ShotSpotter Tech Note 098 / 14 January 2020 Accuracy of acoustic gunshot location the solution vector is given by   x   x2 + y2 + z2 − (ct )2  y  0 0 0 0   1 x2 + y2 + z2 − (ct )2  z  = R†  1 1 1 1  (5)   2  ...   ct      x2 + y2 + z2 − (ct )2 v/c i i i i where v is an error term and R† is the pseudoinverse of R. See (Mathias et al., 2008) for handling of the fully determined case (n = d + 1) , and for a quantification of 1400 m error propagation in multilateration.

3. LeastSquares The “LeastSquares” implementation is another least- squares minimizer, based on time difference of arrivals between pairs of sensors. Equating the squares of the dis- tance and the time-distance gives one equation for each 1400 m sensor i: 2 2 2 2 FIG. 5. Graphical representation of the intersecting circle ap- (xi − x) + (yi − y) + (zi − z) = (cti − ct) . (6) proach characteristic of Iterative Discharge Time algorithm. Subtracting the ith equation from the (i + 1)-st elimi- The sample data is from test 1 at Firing Position 4. nates quadratic terms. Define Xi to be the difference between the LHS (distance) and RHS (time-distance) of the ith difference equation. When is strongest in the medium-wave IR region (Pauli et al., n−1 2004). If the discharge time t∗ is known from muzzle flash 2 X 2 timing (6) reduces to finding the point of intersection of χ = Xi , i=1 circles (or spheres) of known radius c(ti − t∗). This is a simplified version of (7). the minimum value of χ2 is the point at which When no muzzle flash time is available the dis- charge time can be determined iteratively. The “Iter- ∂χ2 ∂χ2 ∂χ2 ∂χ2 = = = = 0. ative Discharge Time” (IDT) implementation uses sim- ∂x ∂y ∂z ∂ct plex gradient descent to find t∗ based on starting value of t∗ = t0 − 1.0, where t0 is the arrival time on the nearest This gives a linear system in d + 1 variables: (earliest) sensor and the constant roughly equal to the mean distance between a shooter and the first reporting a a a b a c a d  x a e  i i i i i i i i i i sensor. The main advantage over pure TDoA algorithms b a b b b c b d   y  b e   i i i i i i i i     i i  is that the range can be bounded, which is helpful when     =   (7) ciai cibi cici cidi   z  ciei  locating sources outside the sensor array. An additional diai dibi dici didi ct diei benefit of all intersecting circle solutions in a forensic con- text is that the location tuple obtained (x∗, y∗, t∗) can where readily be checked using the standard tools of plane ge- ometry, a ruler and a compass. A graphical representa- ai = (xi+1 − xi), tion of an intersecting circles solution is shown in Figure bi = (yi+1 − yi), 5. ci = (zi+1 − zi), di = −c(ti+1 − ti), and E. Geometric Constraints

1 2 2 2 2 2 2 2 2 2 2 Acoustic multilateration can be done in two or three ei = (x + y + z + c t − x − y − z − c t ). 2 i+1 i+1 i+1 i i i i i+1 dimensions. For two-dimensional multilateration, the sensor positions are projected against a plane and the This requires an additional TDoA compared with the multilateration solution returned is computed in this Reddi and MLG implementations. plane. At least three TDoAs are required. For three- dimensional multilateration, the sensor elevation data is 4. Iterative Discharge Time used without modification and the multilateration solu- Combustion of the propellant used firearms gener- tion computed in three-dimensional space. Four TDoAs ates an optical signal known as the muzzle flash that are required for multilateration in three dimensions.

ShotSpotter Tech Note 098 / 14 January 2020 Accuracy of acoustic gunshot location 5 There are two potential advantages of three- dimensional multilateration. First, a 3D straight-line distance propagation model can be used. This is po- tentially more accurate. Second, the elevation of the shooter can be estimated. The downside of 3D multilat- eration is that the additional degree of freedom allowed by three-dimensional multilateration can to less ac- curate 2D results if the sensor position matrix is poorly conditioned, e.g. the range of vertical elevations of re- porting sensors is small compared with the horizontal spacing between them. With poorly-conditioned arrays, small errors in the measurements of arrival time, sensor position, or speed of sound may result in large changes in the shooter’s putative elevation. There are plausible use cases for detecting gunshots above ground level, including locating shots fired from FIG. 6. Method for constructing a sensor array through a the upper floors of a structure and assisting in the classifi- ground plane by reflection. This permits use of elevation data cation of aerial fireworks. Nevertheless the vast majority from the remote sensors while constraining the output to the of firearms are discharged at ground level, so a practical specified plane. approach is to do the bulk of pulse selection in two di- mensions, and then refine the solution using a 3D model when sufficient data are available. z-axis component of wind vector ~v assumed to be zero, An approach that enables use of a 3D propagation the wind-corrected position of the sensors is given by: model while avoiding the instability of a full 3D solution is to constrain the shooter location to a two-dimensional plane. This “2.5D” method (Calhoun, 2013) refines an " 0 # " # " # xi xi vx initial 2D solution by assuming the shooter is standing 0 = − (ti − t∗) (9) on the ground (or on the roof of a building) and con- yi yi vy structing R with a duplicate set of sensors with identical arrival time but position reflected through the horizontal t v v plane containing the shooter, Figure6. The method re- where i the arrival time at each sensor and x and y x y− quires use of a digital elevation and/or building model are the - and components of the wind vector. The discharge time t∗ is not known a priori but it can be to provide an estimate for z∗, the z-elevation of the shooter. With ground plane normal toz ˆ, each TDoA estimated by subtracting an appropriate value from the arrival time at the first reporting sensor. A suitable value tuple (xi, yi, zi, ti) in (4) is supplemented with a second TDoA tuple (x , y , 2z −z , t ). This doubles the number is the (historic) mean distance from the shooter to the i i ∗ i i . of columns in (4) and the number of rows in (5) but no first reporting sensor; a value of 1 0 s is appropriate for / 2 changes in algorithm are required. The solution will be arrays with sensor densities in the range of 2 sensors km to 12 sensors/km2. The wind-correction process can be constrained to elevation z∗ by the symmetry of the input data. repeated with a more accurate value after initial compu- tation of discharge time t∗. Other deleterious effects of wind are not so easily F. Weather Effects handled. Wind increases the background noise detected by outdoor (Raspet et al., 2006), an effect Atmospheric conditions affect sound propagation that can be ameliorated but not entirely eliminated with and therefore the accuracy of an acoustic gunshot loca- proper windscreens (Hosier and Donavan, 1979; Lin et al., tion system. The speed of sound varies only slowly with 2014; Schomer et al., 1990; Wuttke, 1992). Wind noise re- temperature, and little with humidity or pressure, so the duces the signal-to-noise ratio of gunshot impulses, mak- dry air relationship for the speed of sound c may be used ing them harder to detect. Gradients in wind speed and with acceptable accuracy. This is: √ temperature with elevation refract the sound, bending c = 20.03 T + 273.15 m s−1 (8) it upwards in the upwind direction and downwards in the downwind direction (Franke et al., 1988; Wiener and where T is the temperature in ◦C. Keast, 1959; Wilson, 2003). Upwind refraction creates Sound energy is transmitted as a compression wave a “shadow zone” where the gunshot signal is not de- in a fluid; a moving fluid carries the sound energy with tectable. Because of the potential lack of participation it. The multilateration routines of SectionIID assume from upwind sensors during windy conditions, additional a stationary medium, but the effects of a homogeneous sensors must be to deployed to enable successful mul- moving fluid can be incorporated by shifting the apparent tilateration in all weather conditions. The ShotSpotter position of each sensor to account for air motion from system does not otherwise compensate for the effects of when the shot is fired to when it is detected. With the wind or temperature gradients.

6 ShotSpotter Tech Note 098 / 14 January 2020 Accuracy of acoustic gunshot location availability of high-accuracy real-time kinematic (RTK) sensor GPS chipsets will reduce or eliminate the need for posi- tion averaging in future multilateration systems.

0.7 LTA 0.6 by hour wind apparent by minute 0.5 position of sensor y 0.4 uenc q

fre 0.3

0.2 FIG. 7. Adjustment of sensor positions to take homogeneous fluid movement into account. Energy is propagated from 0.1 source to sensor via a combination of bulk fluid flow and 0 acoustic propagation. The effects of bulk fluid flow can be 0.0 2.5 5.0 7.5 10.0 12.5 15.0 2D distance from centroid (m) incorporated by shifting the apparent position of the sensor to the position that would have received the signal in the absence of fluid flow. FIG. 8. Horizontal GPS performance of a typical stationary sensor, showing the distance from the centroid of GPS mea- surements sampled once per minute, of the hourly averages, III. SYSTEM DESIGN and of the long-term average of hourly values. 50% CEP is slightly worse than predicted by the datasheet but averag- A. Array design ing reduces the RMS distance from the centroid to less than 0.02 m. A typical deployment density is 2 sensors/km2 to 12 sensors/km2, with the density dependent on the den- sity of structures and foliage in the covered area. The low Audio sound pressure level is measured using end of this range is used in open areas where few struc- Kingstate KECG2742WBL waterproof electret micro- tures impede acoustic propagation, such as anti-poaching phones and digitized using a Cirrus Logic WM8737 deployments; higher sensor densities are used in areas analog-to-digital converter, which samples 24-bit audio with a high density of structures, high background noise data at 48 kHz. Microphone sensitivity is −42 ± 3 dB (traffic, rapid transit systems), difficult wind conditions, SPL, giving a full-scale digital output of approximately or unfamiliar environments. Sensors are installed on el- 93 dB SPL. Network connectivity is provided by an on- evated locations such as rooftops and utility poles to in- board cellular data module. crease the number of near line-of-sight audio paths, and For performance reasons, the pulse localization algo- to minimize background noise. Wind noise is mitigated rithm described inIIB is implemented as a discrete-time with a 3.5 cm layer of open-cell foam around the micro- algorithm. The digitized input stream is split up into phones. 2048-length chunks with 50% overlap so that a Hann win- dow can be applied without data loss. After windowing, B. Sensor processing data is converted into the frequency domain for filter- ing and analysis. A typical pulse localization response is All signal processing and pulse detection opera- shown in Figure3. tions are performed in the field on remotely-deployed single-board computers based on the Texas Instruments AM335x platform. Sensor position is provided by a u- system σ (µs) blox MAX 7 GPS chipset, and the Linux system clock GPS timepulse 3 × 10−2 is disciplined using the PPS signal from the GPS. The Linux system clock 1 × 10−3 u-blox MAX-7 series of GPS chipsets have a datasheet 2 location accuracy of 2.5m (50% circular error probability Pulse start measurement 1 × 10 (CEP)) and timepulse accuracy 30 n sec (RMS). Actual performance depends on the satellite constellation visi- ble from the installed sensor position. Because sensors TABLE I. Scale of contributions to pulse arrival time error are rarely moved, averaging over long periods of time is a feasible method for improving location precision. Each hour, the mean position over the previous hour is stored, Pulse arrival time measurements are derived from au- and a long-term average position re-estimated based on dio synchronized to the GPS PPS timepulse. As shown values from up to 180 days of hourly records, (Figure8) in TableI, the timing errors associated with the GPS with the multilateration calculations making use of the system are negligible compared with the uncertainty in long-term averages. It is expected that the increasing pulse arrival time measurement. The net effect of all

ShotSpotter Tech Note 098 / 14 January 2020 Accuracy of acoustic gunshot location 7 timing errors is estimated by running the pulse detec- code; K) time-of-date counters; L) individual shot loca- tion algorithm on gunshot-like impulsive signals synchro- tions; M) power spectrum; N, O, P) pulse feature coun- nized with GPS PPS. This measurement takes into ac- ters; Q, R) recent incident counters; S) logo. Discrete count multiple sources of error. The measured timing wavelet transforms are performed using the biorthogonal error through the ShotSpotter sensors has a mean of 2.2 wavelet and scaling functions. µ = −316 µs with a standard deviation of σ = 99.6 µs, Classification of the mosaic images is performed us- with a typical measurement shown in Figure9. The pulse ing the ResNet (He et al., 2016) image classifier trained arrival time data provided and used for multilateration using field-collected data labelled by human reviewers. in the current work are to millisecond precision. Each mosaic image (one from the nearest sensor, and one from the second-nearest) is classified independently; the 125 outputs of the two classifiers are combined to minimize the likelihood of false negatives. In the vast majority of 100 cases, “ground truth” (e.g. shell casings, video record- ings) is not available, and it is to be expected that some 80 training data are misidentified. s 60 count 40

20

0 -10 -1250 -1000 -800 -600 -400 -200 0 200 400 600 750 microseconds

FIG. 9. Pulse start timing measurements using simulated gunshot impulses triggered by GPS timepulses

The audio processing code analyzes the first 250 ms following pulse arrival time to determine the likelihood that the impulse is due to a gunshot muzzle blast. Mea- sured characteristics of the impulse include the integrated power of the impulse, the shape of its envelope, and a nor- malized power spectrum. These data are transmitted to a common endpoint for the multilateration computation. A

C. Classification B The original 48 kHz data is discarded after pulse pro- C cessing; data downsampled to 12 kHz is cached on the sensor for 30 hours to support forensic analysis. Follow- D ing detection of a potential gunshot, a 2-second subset of E downsampled (12 kHz) FLAC-encoded audio is retrieved from the two closest sensors and used to build an image mosaic (Figure 10) comprising features characteristic of F G H I the gunshot audio on each sensor and features character- istic of the incident as a whole. A full description of image mosaic construction is outside of the scope of the present work, but the tiles comprising the image can be summa- J K L M N O P Q R S rized as follows: A) waveform image; B) discrete wavelet spectrogram of the de-noised waveform; C) pulse time- FIG. 10. The top image shows a typical mosaic image used for of-arrival markers aligned using the shooter-sensor time machine classification with ResNet image classifier. This ex- delay computed via multilateration; D) discrete wavelet ample is from a 9 mm firearm discharged at Firing Position 8. spectrogram of the noise (complement of tile B above); Each image used for classification is comprised of 19 individ- E) wavelet transform of the first impulse; F) waveform ual tiles; some tiles are derived from a 2-second subset of 12 of the first impulse; G) participating area, as defined by kHz audio, while others are derived from the characteristics the Voronoi diagram of participating sensors; H) location of recent nearby incidents I) plots of various per-sensor of the incident as a whole. See text for tile descriptions. parameters as a function of distance; J) version-tracking

8 ShotSpotter Tech Note 098 / 14 January 2020 Accuracy of acoustic gunshot location Incidents classified as gunfire are pushed to the pub- lic safety agency’s dispatch system and/or mobile de- vices. All of the pulse data associated with an inci- dent is stored in a database so that the measurements made by the remote sensor are available for later anal- ysis. If a forensic report is requested (typically in the course of a criminal investigation) within 24 hours, eight seconds of 12 kHz downsampled audio may be retrieved from sensors participating in the incident. The down- sampled audio is invaluable for verifying that the pulse selection algorithms have grouped the input pulse data into appropriate subsets for multilateration.

D. Weather Measurements Reliable temperature data with a precision of ±1 ◦C are available via NWS METAR readings from major air- FIG. 11. Firing Position 1, showing the shooter and ports; measurements from Pittsburgh International Air- trap, illustrating the source of the signals used for the test. port (KPIT) and Allegheny County Airport (KAGC) were used in the present work. Wind is highly depen- dent on local conditions and sensor mounting elevation so the airport values can provide only a rough estimate FP description N/M n  ρ of local conditions, but both airports reported negligible 2 wind of 0 m s−1 to 5 m s−1 during the live fire test, so the (m) (sensors/km ) effects of wind were not investigated. FP1 overpass ˜35 m above grade 36/36 17.8 4.14 9.4 FP2 parking lot near top of hill 36/36 14.3 5.20 11.4 IV. DESCRIPTION OF LIVE FIRE TESTS FP3 intersection on high bluff 36/36 9.9 3.49 7.5 ShotSpotter sensor arrays are routinely tested prior FP4 intersection near top of hill 36/36 13.8 4.76 9.4 to active use by law enforcement. The live fire test of FP5 playing field at head of valley 33/36 11.6 2.21 8.5 the ShotSpotter system examined here was conducted in FP6 playing field near top of hill 36/36 13.6 5.54 8.5 Pittsburgh, PA by the Pittsburgh Bureau of Police in FP7 playing field at end of valley 36/36 14.9 7.88 12.4 December, 2018. Pittsburgh has mixture of hilly and flat terrain. The regions covered by these tests primar- FP8 intersection at bottom of valley 36/36 11.2 2.18 9.9 ily contain detached structures one to three stories in FP9 parking lot on sloped region 36/36 10.6 6.93 8.0 height, comparable to the scale of structures in many other American cities. Most sensors are installed on TABLE II. Realtime performance at the nine firing positions rooftops; the major component of the variance in sen- (FP) analyzed in present study. Buildings at most sites com- sor elevation is due to the hilly terrain. Several of the prised detached residential structures 1–3 stories in height, firing positions were adjacent to institutional buildings with some larger commercial, residential, and institutional that generated loud, sharp echoes. buildings. Ratio N/M is number of shots N detected out of Officers secured the target area prior to each test for shots fired M; n is mean participating sensor count per shot; safety reasons. Live rounds were discharged into a bul- survey error  is the distance from the acoustically-determined let trap at distance ≈ 3 m from the firearm, Figure (11). centroid to the survey location determined by smartphone- All shots at a giving firing position were discharged with assisted GPS. Sensor density ρ is in sensors/km2. This is 2D the muzzle of the firearm pointed in the same direction, performance using the algorithm matching the most sensors which was not otherwise specified. The survey location of each firing position was determined by ShotSpotter for each shot. personnel during the test using a smartphone applica- tion and qualitatively verified using aerial photographs available on Google Earth. Survey error  was not well- handguns at each firing position (.45 cal, .40 cal, 9 mm). characterized during the test but typical performance of The test sequence was repeated at each of nine firing po- such devices (which make use of signals from cellular and sitions, for a total of 162 tests comprising 324 shots. A WiFi networks in addition to GPS) when used outdoors general description of each firing position is given in Ta- with good sky view is on the order of  = 2.5 m. bleII. Temperature during the test was −1 ± 1◦C with Testing followed the standard firing sequence used by light (0–2 m/s) wind. During the real-time tests, the ShotSpotter. This comprises twelve shots (three single system detected 100% of incidents and located 96.9% of shots and three groups of three shots) for each firing po- incidents within a 25 m benchmark criterion. The cumu- sition and tested weapon. This test used three different lative distribution function of survey error below 25 m for

ShotSpotter Tech Note 098 / 14 January 2020 Accuracy of acoustic gunshot location 9 0SoSotrTc oe08/1 aur 00Acrc faosi uso location gunshot acoustic of Accuracy 2020 January 14 / 098 Note Tech ShotSpotter 10 itnyagrtm opc eso usssial o mul- for suitable pulses of sets pick to ShotSpot- algorithms con- noise combinatorial sistency test. and impulsive gunfire pattern-matching various other the uses to ter and unrelated signals are that multipath sources as location multilateration well for useful as are prop- that These line-of-sight paths near agation test. with each around muzzle-blast range include time the during triggered each for different is arbi- that an position. to firing origin relative unpublished) provided (and sensor are retal- trary the dataset of the accordingly, risk in owners; the locations sensor property of redact audio against because routinely kHz records iation law 12 trial of six from Courts to locations test. up each and for pulse position) files sensor acoustic include and ratio, materials signal-to-noise power time, arrival These (impulse data materials. plementary position. firing an each within of located radius sensors m 800 to study analysis present align- performance The in com- limits requests. is the forensic by limit servicing adopted when range policy pany retrieval The audio the position. within with firing ment located the sensors of selected m 800 from the seconds Following audio eight additional to use. anal- up later of retrieved for pulse machine personnel database on-sensor ShotSpotter a facilitate test, the in to stored of are audio results ysis kHz The 12 classification. of samples per-shot. second than rather per-test is ShotSpotter scoring single real-time so a The into incident, shots closely-spaced 12. multiple Figure bundles system shown is tests all incident. single a bursts as 3-shot error scored incidents, and survey fire detected live of are For function testings. distribution live-fire Cumulative during 12. FIG.

h us aaicuearcr fipliesounds impulsive of record a include data pulse The sup- as available are tests these from data Selected two- requests system the activation, each Following Fraction of incidents 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 0.0 0.1 0.0 2.5 5.0 7.5 10.0 Survey Error,m 12.5 15.0 Survey error(m) 17.5 20.0 22.5 25.0 hwta Dlcto eut r very are The results location computation. 2D that location algo- show final ) IV MLG the (Table results the for in used multilateration; algorithm was for any rithm use sets to pulse calcula- of permitted selecting was multilateration effect system the the The quantify in tion. to data 3D) elevation 2.5D, including (2D, constraints ric constraint array geometric the of makes effect This accuracy. the location km. of on 1 study over a building m for plus 160 suitable entire to sen- terrain its up has of (comprising over study height) m under change array 10 elevation Pittsburgh just sor the of extent, range km vertical 5 a has Valley constraint geometric of Effects B. study. the of remainder implementation the MLG in The used SVD. was using since up computed time, be set running can to fastest required the computation has the three ar- or also two not and in does works dimensions sensor, solution, single a a it overweight for the bitrarily because TDoAs only data of requires number input implementation minimum MLG same The the for longer iterative. times is MLG ten or roughly Reddi time running than the a and has TDoA routine extra stabil- IDT an LeastSquares and requires The accuracy LeastSquares the good rest. but ity, yield the routines the of IDT to related all weight and to more than gives which sensor report- reference, nearest a first algo- as the sensor four uses ing implementation all Reddi from The obtained rithms. unsur- are results model—so similar sensors propagation several prisingly straight-line the pre- at a times the assuming arrival measured between and difference dicted the context. problem—minimizing safety public a in measure error considered appropriate is the distance co- Two-dimensional two-dimensional the matrix. of variance eigenvalues the of roots square indtrie ysathn GPS; loca- smartphone survey by the determined to tion centroid multilateration . III acoustic Table the in multilatera- well error shown 2D 17.5, survey are The unambiguous implementation to by for 9.6 Results needed from partic- tion. four of ranged number the shot acoustic mean over per shortest The sensors of m. 800 ipating tuples within were pulses data and path input MLG, imple- The LeastSquares, 2D IDT). four (Reddi, the available of performance mentations the evaluate to offline Implementations Multilateration A. pro- ANALYSIS are V. test) each of shot materials. each supplementary for as pulses vided of algorithms selection tuples pulse the the (as in of revealed output not the work, are present routines these While tilateration. eere-analyzed were ) II (Table positions firing nine The l niet eerlctdudrtetregeomet- three the under relocated were incidents All Central California’s in array ShotSpotter a While mathematical same the solve routines four All  stetodmninldsac from distance two-dimensional the is R σ ssml and simple is 1 and σ 2 r the are R † htpte ehNt 9 4Jnay22 cuayo cutcgnhtlcto 11 location gunshot acoustic of Accuracy 2020 January 14 / 098 Note Tech location ShotSpotter best-fit the locating sen- be the may of system plane the well- the so path in mul- sors, locating 2D a implicitly distance. along is straight-line tilateration roofline building 2D the the nearest by the above approximated travels at path then diffracted and one makes level model. propagation of a use as the distance to filled straight-line due improvement The 3D apparent no plot. with each similar, sensors of those center of hull the convex the at is located limit” “detection are dashed which shots. the of shot; 1–9, 50% one Positions least least Firing at at in in to participated reporting relative that sensors shown those positions show circles Sensor 13. FIG. osbeepaaini htaso rda ground at fired shot a that is explanation possible A

relative northing (m) relative northing (m) relative northing (m) -1000 -1000 -1000 1000 1000 1000 -800 -600 -400 -200 -800 -600 -400 -200 -800 -600 -400 -200 200 400 600 800 200 400 600 800 200 400 600 800 -1000 -1000 -1000 0 0 0 detect limit no detect detect firing point detect limit no detect detect firing point detect limit no detect detect firing point -750 -750 -750 iigPsto iigPsto iigPsto 9 Position Firing 8 Position Firing 6 Position Firing 7 Position Firing 5 Position Firing 3 Position Firing 4 Position Firing 2 Position Firing 1 Position Firing -500 -500 -500 -250 -250 -250 relative easting(m) relative easting(m) relative easting(m) 0 0 0 250 250 250 500 500 500 750 750 750 1000 1000 1000

relative northing (m) relative northing (m) relative northing (m) -1000 -1000 -1000 1000 1000 1000 -800 -600 -400 -200 -800 -600 -400 -200 -800 -600 -400 -200 200 400 600 800 200 400 600 800 200 400 600 800 -1000 -1000 -1000 0 0 0 detect limit no detect detect firing point detect limit no detect detect firing point detect limit no detect detect firing point -750 -750 -750 -500 -500 -500 -250 -250 -250 relative easting(m) relative easting(m) relative easting(m) 0 0 0 fhg cuaywt rcso fafwmtr even meters few a of are locations precision resulting with The accuracy terrain. high hilly of in gun- of even multilateration shots acoustic for appropriate is straint by introduced small. 2D error is the the process ground, this Because height above than sensors larger typical shooter. much of so the are above sensors between slightly distances point a of 250 250 250 hs eut ugs htte2 emti con- geometric 2D the that suggest results These 500 500 500 750 750 750 1000 1000 1000

relative northing (m) relative northing (m) relative northing (m) -1000 -1000 -1000 1000 1000 1000 -400 -200 -800 -600 -400 -200 -400 -200 -800 -600 -800 -600 200 400 600 800 200 400 600 800 200 400 600 800 -1000 -1000 -1000 0 0 0 detect limit no detect detect firing point detect limit no detect detect firing point detect limit no detect detect firing point -750 -750 -750 -500 -500 -500 -250 -250 -250 relative easting(m) relative easting(m) relative easting(m) 0 0 0 250 250 250 500 500 500 750 750 750 1000 1000 1000 2SoSotrTc oe08/1 aur 00Acrc faosi uso location gunshot acoustic of Accuracy 2020 January 14 / 098 Note Tech ShotSpotter 12 fired. be might shot a provide of which not from floor structure do the multi-story identify study a to this determination in elevation used sufficient arrays planar er- largely the the However, in accuracy. ror location obtained sensors 2D results acceptable the of non- multilateration, show number a 3D sufficient for contain available a array are When the component. comprising plane sensors the when

relativeposition (m ) relativeposition (m ) relativeposition (m ) -10 -10 -10 10 10 10 -4 -2 -8 -6 -8 -6 -4 -2 -8 -6 -4 -2 0 2 4 6 8 0 2 4 6 8 0 2 4 6 8 -10 -10 -10 z -8 -8 -8 − xsi ih n h eut hwta the that show results the and high, is axis -6 -6 -6 iigPsto iigPsto iigPsto 9 Position Firing 8 Position Firing 6 Position Firing 7 Position Firing 5 Position Firing 3 Position Firing 4 Position Firing 2 Position Firing 1 Position Firing -4 -4 -4 I.1.Rslso L mlmnainudr2 osritfrFrn oiin 1–9. Positions Firing for constraint 2D under implementation MLG of Results 14. FIG. relative position(m) relative position(m) relative position(m) -2 -2 -2 0 0 0 2 2 2 4 4 4 6 6 6 survey shots survey shots survey shots 8 8 8 10 10 10

relativeposition (m ) relativeposition (m ) relativeposition (m ) -10 -10 -10 10 10 10 -8 -6 -4 -2 -8 -6 -4 -2 -8 -6 -4 -2 0 2 4 6 8 0 2 4 6 8 0 2 4 6 8 -10 -10 -10 -8 -8 -8 -6 -6 -6 -4 -4 -4 relative position(m) relative position(m) relative position(m) -2 -2 -2 0 0 0 Dad25 emti constraints. geometric 1 ele- 2.5D to and shooter 2D set the arbitrarily as constraint, is vation 3D only the is under error survey meaningful elevation The shooter algorithm. presumed tilateration between 1 difference of RMS elevation the is which 2 2 2 as hw h lvto uvyerror survey elevation the shows also IV Table 4 4 4 6 6 6 survey shots survey shots survey shots 8 8 8 . 10 10 10 bv rd n h upto h mul- the of output the and grade above m 5

relativeposition (m ) relativeposition (m ) relativeposition (m ) -10 -10 -10 10 10 10 -8 -6 -4 -2 -8 -6 -4 -2 -8 -6 -4 -2 0 2 4 6 8 0 2 4 6 8 0 2 4 6 8 -10 -10 -10 -8 -8 -8 -6 -6 -6 . bv rd ne the under grade above m 5 -4 -4 -4 relative position(m) relative position(m) relative position(m) -2 -2 -2 0 0 0 2 2 2 4 4 4 6 6 6 survey shots survey shots survey shots 8 8 8 10 10 10  z , Algo FP N/M n  σ σ diffraction 1 2 sensor (m) (m) (m) apparent source Iterative FP1 36/36 17.5 3.14 0.62 0.41 actual source shortest acoustic path Discharge FP2 36/36 17.5 5.14 1.40 0.25 Time FP3 36/36 17.5 0.61 1.40 0.83 (IDT) FP4 36/36 17.5 4.09 2.33 0.56 FP5 36/36 14.0 3.25 1.71 0.93 FIG. 15. Schematic side view of how sound from a muzzle FP6 36/36 14.0 5.21 1.29 0.40 blast discharged near ground level relies on sound diffraction FP7 36/36 13.9 7.17 0.94 0.39 to reach a roof-mounted sensor. From the point of view of the sensor, the source appears to be an above-ground-level source FP8 36/36 14.0 2.67 1.39 0.47 with attenuated amplitude and nearly 2D propagation path. FP9 36/36 9.9 6.58 0.66 0.55 Reddi FP1 36/36 9.9 3.55 1.03 0.62 FP2 36/36 9.8 4.66 1.05 0.33 FP3 36/36 9.9 3.56 2.40 0.74 sensor FP4 36/36 13.8 7.69 5.52 1.86 apparent sources sensor FP5 36/36 13.6 2.13 6.60 0.77 FP6 36/36 11.2 6.30 0.76 0.50 FP7 26/36 13.6 18.37 5.49 3.21 FP8 36/36 11.4 2.15 1.39 0.32 FP9 36/36 11.4 6.78 5.06 0.84 LeastSquares FP1 36/36 11.4 3.09 0.62 0.35 actual source FP2 36/36 11.4 4.01 1.68 0.20 FP3 36/36 13.6 0.75 1.31 0.54 sensor FP4 31/36 13.6 3.93 1.35 0.71 FP5 36/36 13.6 3.89 1.76 0.85 FIG. 16. Schematic top view of the shortest acoustic path FP6 36/36 13.6 5.62 1.47 0.50 from a shot discharged near ground level to several rooftop- FP7 36/36 14.9 7.82 1.13 0.48 mounted sensors. Diffraction shifts the apparent position of the source from the point of view of each reporting sensor, FP8 35/36 9.6 2.48 1.95 1.60 but errors from multiple sensors tend to cancel when sensors FP9 36/36 14.9 6.33 1.25 0.36 surround the actual source. MLG FP1 36/36 14.9 2.94 0.55 0.42 FP2 36/36 11.2 4.03 1.87 0.31 FP3 36/36 11.2 0.29 1.49 0.23 C. Effects of sensor density FP4 36/36 10.8 4.55 1.40 0.60 A reporting sensor is one on which at least one gun- FP5 36/36 11.2 4.20 1.97 0.67 shot impulse is detected programmatically by a sensor from shots fired at a particular location. A participating FP6 36/36 10.6 5.28 1.25 0.38 sensor is one identified by the pulse selection algorithms FP7 36/36 10.5 7.86 0.96 0.37 as a member of a subset suitable for multilateration. FP8 36/36 10.1 2.77 1.89 1.51 This series of firing tests was conducted on a night FP9 36/36 10.6 5.76 0.91 0.56 with still air after autumn leaf drop, resulting in good acoustic propagation of the gunshot sounds. The report- ing sensor count was as high as 21 for the most power- TABLE III. Performance of several 2D multilateration imple- ful firearm (.45 cal) fired from the elevated position at mentations at nine firing positions (FP). The ratio N/M is FP1; the median number of participating sensors across number of shots N detected out of M shots fired, while n is all weapons and firing positions was 10, well above the the mean number of sensors used in the location. The survey minimum d + 2 = 4 participating sensors required for error  is the 2D RMS distance from the survey location; σ1 unambiguous 2D or 2.5D multilateration. and σ2 are the square roots of the eigenvalues of the covari- To investigate the effects of reduced deployment den- ance matrix, determined using PCA. These correspond to the sity, the multilateration performance of reduced-density standard deviations σX , σY of a bivariate normal distribution. arrays was evaluated using a Monte-Carlo simulation. These simulations make use of the real-time pulse de- tection performance; the simulation is in varying the set

ShotSpotter Tech Note 098 / 14 January 2020 Accuracy of acoustic gunshot location 13 FP N/M n  σ σ  straint. Simulated incidents were filtered using the same 1 2 z pulse selection and filtering criteria used in production (m) (m) (m) (m) systems, with the result that some valid multilateration 2D FP1 36/36 17.53 2.96 0.67 0.28 34.95 solutions were discarded because the signal amplitude on FP2 36/36 14.00 3.60 2.82 0.38 0.22 the strongest participating sensor failed to meet the (ar- bitrary) 73 dB SPL amplitude threshold applied to all FP3 36/36 9.86 0.36 1.43 0.58 0.54 incidents. FP4 36/36 13.72 5.57 1.26 0.75 0.35 The results show that detection rates and location FP5 36/36 11.44 3.30 2.18 0.76 0.00 accuracy increase as the number of participating sensors FP6 36/36 13.61 5.87 1.56 0.76 0.52 increases. With six participating sensors, 96.3% of inci- dents can be located to an accuracy of 15 m or better. FP7 36/36 14.94 4.57 0.48 0.23 0.37 Detection rates and location accuracy continue to im- FP8 36/36 11.17 3.11 2.41 1.59 0.66 prove as the number of participating sensors increases FP9 36/36 10.58 6.44 1.14 0.46 0.71 above six, but additional reporting sensors provide only 2.5D FP1 36/36 17.53 3.02 0.70 0.23 34.95 marginal improvements. The six-sensor result may be in- terpreted as “sufficient to provide good array geometry FP2 35/36 13.58 3.62 2.72 0.35 0.22 after removing non-line-of-sight paths”. FP3 36/36 9.83 0.54 1.21 0.38 0.54 As this technique varies the deployed sensor density FP4 36/36 13.78 5.66 1.43 1.08 0.35 rather than the propagation distance, it is best used to FP5 36/36 11.44 1.96 1.87 0.79 0.00 estimate the precision and accuracy obtainable as a func- tion of the number of reporting sensors, a known quantity FP6 36/36 13.61 6.77 1.07 0.77 0.52 in a forensic context. It is less suitable for predicting the FP7 36/36 14.94 4.91 0.85 0.44 0.37 sensor density required to ensure good detection rates FP8 36/36 11.17 4.96 2.42 1.64 0.66 under non-ideal conditions. The presence of wind, rain, FP9 36/36 10.58 6.15 1.15 0.32 0.71 traffic noise and similar background noise sources reduce signal-to-noise ratio. Furthermore, while the simulation 3D FP1 36/36 17.53 3.76 0.51 0.32 42.40 shows that any set of six reporting sensors will yield accu- FP2 35/36 13.58 4.46 2.56 0.28 14.57 rate multilateration results, implicit in the simulation is FP3 36/36 9.83 2.51 1.95 0.72 45.55 that the reporting sensors are well-distributed, since the FP4 36/36 13.78 5.63 1.35 1.01 4.79 sensors were randomly drawn from a set of participating sensors that fully surround the shooter, as shown in Fig- FP5 36/36 11.44 2.29 3.17 0.73 3.82 ure 13. Wind may refract the sound away from a given FP6 36/36 13.61 6.43 0.81 0.62 20.35 direction entirely, and some barriers (such as highway FP7 36/36 14.94 4.84 1.73 0.81 3.73 embankments or sound walls) may attenuate the sound FP8 36/36 11.17 4.11 2.92 1.66 41.69 below the point of detectability, potentially resulting in a situation where the shooter is far outside the convex FP9 35/36 10.28 5.68 0.86 0.38 18.75 hull of reporting sensors. Because the effect is due to the geometry of the receiver array, the error of a multi- TABLE IV. Performance of MLG multilateration implemen- lateration solution can be estimated using the analytical tation under 2D, 3D, and “2.5D” (3D constrain-to-plane) ge- approach of (Mathias et al., 2008) or using Monte-Carlo ometric constraints. Table columns have the same meaning simulation, in which the shooter location is repeatedly re- as TableIII, with the addition of z, the distance from mul- computed after perturbing the input measurements ac- tilateration elevation to survey elevation. Note that for 2D cording to the measurement error estimates in Section and 2.5D solutions, the elevation coordinate is set arbitrarily III. Because of the high number of participating sensors at 1.5 m above the ground elevation at the latitude, longitude in the Pittsburgh live-fire test, the data published in the of the multilateration results. present work provide a good basis for future study of the effects of array geometry on location accuracy.

VI. CONCLUSION of sensors considered to have been deployed during the test. 25 randomly-generated arrays were constructed at Source location via acoustic multilateration is a well- each firing point for the desired number of participating developed technique that was reduced to practice during sensors. Simulations were run for 4, 5, 6, 8, 10, 12 and the First World War. Inexpensive computation and cel- 15 sensors, corresponding to a sensor density of approxi- lular radio networks allow the use of these techniques by mately 2 sensors/km2 to 7.5 sensors/km2. In some cases automated systems to detect gunshots in near real time. the target array density exceeded the number of sensors For the sensor arrays considered, the multilateration participating in a shot, so the maximum value of partic- algorithm of (Mathias et al., 2008) had the greatest pre- ipating sensors was used. Multilateration was performed cision. Use of a 3D straight-line propagation model (ei- using the MLG algorithm under the 2D geometric con- ther unconstrained or constrained to the ground plane)

14 ShotSpotter Tech Note 098 / 14 January 2020 Accuracy of acoustic gunshot location htpte ehNt 9 4Jnay22 cuayo cutcgnhtlcto 15 location gunshot acoustic of Accuracy 2020 January 14 / 098 Note Tech ShotSpotter to sensors of number sufficient a positions. firing deploying all by at improved accuracy is participation location medium results and row), multilateration rates top detection of (FP1, for participation. robustness test 18 good the See fire ensure that live bottom). sensors show 2 the (FP3, of results during participation density These low participation sensor or column), sensor a row) (left highest to 4 middle of with corresponding (FP6, maximum those 25 sensors, a with of reflect columns) performance simulation shown (right show Monte-Carlo 12 plots positions These a or using column), position. firing (middle determined each arrays, 8 at reduced-density sensors participating randomly-generated, of of arrays random accuracy Location 17. FIG.

relativep osition(m ) relativep osition(m ) relativep osition(m ) -10 -10 -10 10 10 10 -8 -6 -4 -2 -8 -6 -4 -2 -8 -6 -4 -2 0 2 4 6 8 0 2 4 6 8 0 2 4 6 8 -10 -10 -10 pt eotn esr pt eotn esr pt 2rprigsensors reporting 12 to Up sensors reporting 8 to Up sensors reporting 4 to Up sensors reporting 12 to Up sensors reporting 8 to Up sensors reporting 4 to Up sensors reporting 12 to Up sensors reporting 8 to Up sensors reporting 4 to Up -8 -8 -8 -6 -6 -6 -4 -4 -4 relative position(m) relative position(m) relative position(m) -2 -2 -2 0 0 0 2 2 2 4 4 4 6 6 6 survey shots survey shots survey shots 8 8 8 10 10 10

relativep osition(m ) relativep osition(m ) relativep osition(m ) -10 -10 -10 10 10 10 -8 -6 -4 -2 -8 -6 -4 -2 -8 -6 -4 -2 0 2 4 6 8 0 2 4 6 8 0 2 4 6 8 -10 -10 -10 -8 -8 -8 -6 -6 -6 iigPsto 3 Position Firing 6 Position Firing 1 Position Firing -4 -4 -4 relative position(m) relative position(m) relative position(m) -2 -2 -2 0 0 0 2 2 2 4 4 4 6 6 6 survey shots survey shots survey shots 8 8 8 10 10 10

relativep osition(m ) relativep osition(m ) relativep osition(m ) -10 -10 -10 10 10 10 -4 -2 -8 -6 -4 -2 -4 -2 -8 -6 -8 -6 0 2 4 6 8 0 2 4 6 8 0 2 4 6 8 -10 -10 -10 -8 -8 -8 -6 -6 -6 / km -4 -4 -4 relative position(m) relative position(m) relative position(m) 2 -2 -2 -2 o6sensors 6 to 0 0 0 2 2 2 4 4 4 6 6 6 / survey shots survey shots survey shots km 8 8 8 2 Firing . 10 10 10 6SoSotrTc oe08/1 aur 00Acrc faosi uso location gunshot acoustic of Accuracy 2020 January 14 / 098 Note Tech ShotSpotter 16 identi- be may more inputs or five multipath With error-inducing corrected. sensors, not produces but 3-tuple a solution) each different of (since a presence detected be the can sensors, error line- four timing the With of estimates time. travel good of-sight are the estimate TDoAs to the used that be likelihood must information analysis) Additional waveform as errors. un- (such timing robust of line-of- not presence near is the solution der are fully-determined paths the acoustic but produce sight, when can result dimensions) accurate two an in three (nominally better quired provide to area roof the the in both structures precision. elevation at tall of positioned of areas base be is coverage and should structure In elevated sensors an building. concern, from a fired discharge of shots firearm of stories where elevation upper the the identify from to adequate digi- not vs was 17 accuracy of RMS model an elevation yielding tal lower, solutions much 3D was full estimates elevation with of shoot- precision multiple The involve may ers. that situations of foren- analysis performing 0 sic when essential of is accuracy) accuracy relative relative High (or precision 2D between accuracy conditions, 0 2D these a provided Under multilateration the acoustic model. over propagation accuracy 2D location simpler improve significantly not did comparison. for included is 12 Figure from approximately of density firing each sensor sensors 2 at a sensors to participating 10 corresponding or arrays position, 8, random 6, 25 using 5, shots 4, all comprising simu- relocating each on for based CDF is The lations sensors. simu- participating vary- of of containing numbers arrays ing (CDF) random with function accuracy distribution detection lated Cumulative 18. FIG. . 6mt 6 to m 36

eeto ntemnmmnme fsnosre- sensors of number minimum the on Detection Fraction of incidents 0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 0.0 / km . 2.5 4mwt epc osree oainada and location surveyed to respect with m 44 2 o5sensors 5 to 5.0 7.5 10 8 / . 6 10.0 km .Tearygoer tested geometry array The m. 8 Survey Error,m 5 2 h D ftelv-r test live-fire the of CDF The . 12.5 15.0 4 Survey error(m) 17.5 . 8mt 2 to m 48 20.0 22.5 . 2m. 82 25.0 1 eal,D . ek .D,adMhr .C ( C. R. Maher, and D., S. ( Beck, R., W. D. Begault, K. Marr, and H., Nakasone, D., S. Beck, Inc. ShotSpotter, in interest detection. gunshot for array and effective deploying, an designing, maintaining for particular, Manager in Project thank Bazi and Athnaiel also Team, the We Operations of community. ShotSpotter test their the live-fire in comprehensive system a ShotSpotter conducting for lice ACKNOWLEDGMENTS we topic a work. is future sensor and in economical address location, effective, to gunshot seek of acoustic design for the arrays in would struc- value reflection of ground of and effects be wind, A combined foliage, sensors. terrain, the of tures, number incorporates minimal that a con- using model weather so all do under discharges area and firearm coverage ditions, the that outdoor of of one part fraction any is from high the configuration a at detect deployment conditions. will areas, weather sensor adverse built-up ideal in highly or The in areas, coverage three) of least (preferably edge at en- count but sensor help participating six, arrays adequate density an in Higher participation sure sensor sufficient deployments. ensure approximately practical to of needed is density sity sensor deployed corre- sensors 3 a criterion six-sensor to in- The sponds sensors only providing participating improvement. six above of marginal sensors number additional with the creases, as continue accuracy improve and par- to rate of sensors Detection set spatially-distributed reporting sensors. a ticipating six from reliably of random at are arrays drawn accuracy arbitrary and with precision obtained arrays excellent sensor that random with show Simulations rejected. and fied ek .D ( D. S. Beck, ( C. Goldstein, and D., Aubin, ( L. Liu, and G., D. Albert, ( R. J. Aguilar, n ulso erln-fsgtple o ahso htaesuit- are that shot each at available com/ShotSpotter/research.accuracy-of-gunshot-location for currently are pulses multilateration line-of-sight for properties, able near pulse of files, tuples audio and containing materials Supplementary n oit ofrne 09ASItrainlCneec on Conference International Forensics AES Audio 2019 Conference: in Society techniques,” ing analysis gunshot audio forensic ram, h ora fteAosia oit fAmerica of Society Acoustical the of Journal small 129 by The generated waveforms gunshot firearms,” acoustic recorded in tions Audio on Conference International AES Forensics 2019 Conference: in ety receivers,” uncalibrated from events of Journal America The of environment,” Society urban Acoustical an the in propagation pulse tic Society Engineering Audio the 280–291. of Journal enforcement,” t etr lisAon ol a I War Society). World Mathematical Around and France Allies in Western Communities Its and Practices Mathematical matics: h uhr r mlydb n oda ownership an hold and by employed are authors The Po- of Bureau Pittsburgh the thank authors The 4,1748–1759. (4), / km . 2019 2 2015 nteary tde;ahge esrden- sensor higher a studied; arrays the in .“h rdwe:Ascaigmlil audio multiple Associating when: fired “Who ). . .“uso eeto ytm ncvla law civilian in systems detection “Gunshot ). 2010 2014 .“h ffc fbidnso acous- on buildings of effect “The ). ). 127 h a fGn n Mathe- and of War The 3,1335–1346. (3), ui niern Soci- Engineering Audio , 42 4–4 (American 144–149 , 2019 https://github. ui Engineer- Audio 2011 .“vriwof “Overview ). .“Varia- ). 63 . (4), Boashash, B. (2015). Time-frequency signal analysis and process- Mehra, R., Raghuvanshi, N., Chandak, A., Albert, D. G., ing: a comprehensive reference (Academic Press). Keith Wilson, D., and Manocha, D. (2014). “Acoustic pulse Brustad, B. M., and Freytag, J. C. (2005). “A survey of audio propagation in an urban environment using a three-dimensional forensic gunshot investigations,” in Audio Engineering Society numerical simulation,” The Journal of the Acoustical Society of Conference: 26th International Conference: Audio Forensics in America 135(6), 3231–3242. the Digital Age. National Law Enforcement and Corrections Technology Center Calhoun, R. B. (2011). “Systems and methods of processing im- (2007). “Spot the Shot,” TechBeat 1–2. pulses including bullet pulses and/or muzzle pulses in association Parker, M., Ketcham, S., and Cudney, H. (2007). “Acoustic wave with time domain representations” US Patent 7,961,550. propagation in urban environments,” in 2007 DoD High Perfor- Calhoun, R. B. (2013). “Systems and methods with improved mance Computing Modernization Program Users Group Confer- three-dimensional source location processing including constraint ence, IEEE, pp. 233–237. of location solutions to a two-dimensional plane” U.S. patent Pasareanu, S. M., Burdisso, R. A., and Remillieux, M. C. (2018). 8,369,184 (Feb 5,2013). “A numerical hybrid model for outdoor sound propagation in Don, C. G., and Cramond, A. J. (1987). “Impulse propagation in complex urban environments,” The Journal of the Acoustical a neutral atmosphere,” The Journal of the Acoustical Society of Society of America 143(3), EL218–EL224. America 81(5), 1341–1349. Pauli, M., Seisler, W., Price, J., Williams, A., Maraviglia, C., Embleton, T. F. W. (1996). “Tutorial on sound propagation out- Evans, R., Moroz, S., Ertem, M. C., Heidhausen, E., and doors,” The Journal of the Acoustical Society of America 100(1), Burchick, D. A. (2004). “Infrared detection and geolocation of 31–48. gunfire and ordnance events from ground and air platforms,” Finan, J. S., and Hurley, W. J. (1997). “McNaughton and Cana- Technical Report ADA460225 . dian operational research at Vimy,” Journal of the Operational Raspet, R., Webster, J., and Dillion, K. (2006). “Framework for Research Society 48(1), 10–14. wind noise studies,” The Journal of the Acoustical Society of Franke, S. J., Raspet, R., and Liu, C. H. (1988). “Numerical pre- America 119(2), 834–843. dictions of atmospheric sound-pressure levels in shadow zones,” Reddi, S. S. (1993). “An exact solution to range computation with The Journal of the Acoustical Society of America 83(2), 816–820. time delay information for arbitrary array geometries,” IEEE Friedlander, F. G. (1946). “The diffraction of sound pulses i. Transactions on Signal Processing 41(1), 485–486. diffraction by a semi-infinite plane,” Proceedings of the Royal Remillieux, M. C., Corcoran, J. M., Haac, T. R., Burdisso, R. A., Society of London. Series A. Mathematical and Physical Sciences and Svensson, U. P. (2012). “Experimental and numerical study 186(1006), 322–344. on the propagation of impulsive sound around buildings,” Ap- He, K., Zhang, X., Ren, S., and Sun, J. (2016). “Deep residual plied Acoustics 73(10), 1029–1044. learning for image recognition,” in Proceedings of the IEEE con- Routh, T. K., and Maher, R. C. (2016). “Recording anechoic ference on computer vision and pattern recognition, pp. 770–778. gunshot waveforms of several firearms at 500 kilohertz sampling Hirsch, K.-W., and Bertels, W. (2013). “Estimation of the direc- rate,” in Proceedings of Meetings on Acoustics 171 ASA, ASA, tivity pattern of muzzle blasts,” Proc. AIA-DAGA 961–963. Vol. 26, p. 030001. Hornikx, M. (2016). “Ten questions concerning computational ur- Schomer, P. D., Raspet, R., Wagner, M., Walker, D., and Marshall, ban acoustics,” Building and Environment 106, 409–421. D. (1990). “Methods for detecting low-frequency signals in the Hosier, R. N., and Donavan, P. R. (1979). “Microphone wind- presence of strong winds,” Technical Report ADA223980 . screen performance,” Final Report National Bureau of Stan- Showen, R. (1997). “Operational gunshot location system,” in dards, Washington, DC. Acoustical Engineering Div. . Surveillance and Assessment Technologies for Law Enforcement, Kapralos, B., Jenkin, M., and Milios, E. (2008). “Sonel mapping: International Society for Optics and Photonics, Vol. 2935, pp. a probabilistic acoustical modeling method,” Building Acoustics 130–140. 15(4), 289–313. Showen, R. L., Calhoun, R. B., Chu, W. C., and Dunham, J. W. Lawrence, D. S., La Vigne, N. G., Goff, M., and Thompson, P. S. (2008). “Acoustic gunshot location in complex environments— (2018). “Lessons learned implementing gunshot detection tech- concepts and results,” in Sensors, and Command, Control, Com- nology: Results of a process evaluation in three major cities,” munications, and Intelligence (C3I) Technologies for Homeland Justice Evaluation Journal 1(2), 109–129. Security and Homeland Defense VII, S.P.I.E., Vol. 6943, pp. Le Bot, A., and Bocquillet, A. (2000). “Comparison of an integral 694318–1–694318–11. equation on energy and the ray-tracing technique in room acous- Stevens, F., and Murphy, D. (2014). “Spatial impulse response tics,” The Journal of the Acoustical Society of America 108(4), measurement in an urban environment,” in Audio Engineering 1732–1740. Society Conference: 55th International Conference: Spatial Au- Lin, I.-C., Hsieh, Y.-R., Shieh, P.-F., Chuang, H.-C., and Chou, dio, Audio Engineering Society. L.-C. (2014). “The effect of wind on low frequency noise,” in Van der Kloot, W. (2005). “Lawrence Bragg’s role in the develop- 43rd International Congress and Exposition on Noise Control ment of sound-ranging in World War I,” Notes and Records of Engineering (Internoise 2014), Institute of Noise Control Engi- the Royal Society 59(3), 273–284. neering, Vol. 249, pp. 1137–1148. Watkins, C., Green Mazerolle, L., Rogan, D., and Frank, J. (2002). Maher, R. C. (2009). “Audio forensic examination,” IEEE Signal “Technological approaches to controlling random gunfire: Re- Processing Magazine 26(2), 84–94. sults of a gunshot detection system field test,” Policing: An In- Maher, R. C. (2011). “Acoustical modeling of gunshots including ternational Journal of Police Strategies & Management 25(2), directional information and reflections,” in Audio Engineering 345–370. Society Convention 131, Audio Engineering Society. Weber, W. (1939). “Das schallspektrum von knallfunken und Maher, R. C., and Hoerr, E. (2018). “Audio forensic gunshot anal- knallpistolen mit einem beitrag ¨uber anwendungsm¨oglichkeiten ysis and multilateration,” in Audio Engineering Society Conven- in der elektroakustischen meßtechnik,” Ph.D. thesis, University tion 145, Audio Engineering Society. of Berlin. Maher, R. C., and Routh, T. (2015). “Advancing forensic analysis Wiener, F. M., and Keast, D. N. (1959). “Experimental study of gunshot acoustics,” in Audio Engineering Society Convention of the propagation of sound over ground,” The Journal of the 139, Audio Engineering Society. Acoustical Society of America 31(6), 724–733. Maher, R. C., and Shaw, S. R. (2010). “Directional aspects of Wilson, D. K. (2003). “The sound-speed gradient and refraction forensic gunshot recordings,” in Audio Engineering Society Con- in the near-ground atmosphere,” The Journal of the Acoustical ference: 39th International Conference: Audio Forensics: Prac- Society of America 113(2), 750–757. tices and Challenges, Audio Engineering Society. Wuttke, J. (1992). “Microphones and wind,” Journal of the Audio Mathias, A., Leonardi, M., and Galati, G. (2008). “An effi- cient multilateration algorithm,” in Digital Communications- Engineering Society 40(10), 809–817. Enhanced Surveillance of Aircraft and Vehicles, 2008. TI- WDC/ESAV 2008. Tyrrhenian International Workshop on, IEEE, pp. 1–6.

ShotSpotter Tech Note 098 / 14 January 2020 Accuracy of acoustic gunshot location 17 18 ShotSpotter Tech Note 098 / 14 January 2020 Accuracy of acoustic gunshot location