Adaptive Spectral Resonance Suppressor — User Guide
Offline multiband resonance suppression. The script tracks frequency bands that rise above their local spectral neighborhood and reduces those bands dynamically over time.
What this does
The script divides the signal into logarithmically spaced frequency bands, measures the level of each band over time, and compares each band with nearby bands. A band that rises sufficiently above its local baseline can be attenuated. The amount of attenuation then follows the signal through separate attack and release times.
What counts as a resonance here?
In this tool, a resonance is a band whose measured level protrudes above the surrounding spectral baseline. The processor does not search for sinusoidal peaks or estimate a filter Q.
The design is conceptually inspired by dynamic resonance suppressors such as Oeksound Soothe2, but the implementation and controls here are specific to this Praat script.
Quick start
- Select exactly one Sound object in Praat.
- Run
Adaptive_Spectral_Resonance_Suppressor.praat. - Choose a preset. Moderate is a useful general starting point.
- Use Threshold_dB and Max_reduction_dB to control how readily and how strongly the processor reacts.
- Use Sharpness to concentrate reduction toward the strongest detected bands.
- Use Mix for dry/wet blending.
- Leave Draw_visualization on if you want a diagnostic Picture display.
Main controls
| Control | Default | What it changes |
|---|---|---|
| Preset | Custom | Selects Custom, Gentle, Moderate, Aggressive, Vocal Clarity, or De-Harsh. |
| Threshold_dB | 3.0 | How far a band must rise above its local baseline before reduction begins. Lower values react more easily. |
| Max_reduction_dB | 6.0 | Maximum reduction before frequency-dependent protection is applied. |
| Sharpness | 0.5 | Concentrates reduction toward the strongest detected bands in each frame. It does not narrow the filter bands or change Q. |
| Attack_ms | 10 | How quickly reduction rises when a resonance appears. |
| Release_ms | 80 | How quickly reduction relaxes after the resonance subsides. |
| Protect_Hz | 150 | Sets the upper edge of the low-frequency protection region. |
| Protect_amount | 0.7 | Reduces suppression progressively toward the low end; 0 disables this protection and 1 gives the strongest protection curve. |
| Mix | 1.0 | Dry/wet mix: 0 = original, 1 = fully processed. |
| Output_gain_dB | 0.0 | Gain applied after the dry/wet mix. |
| Advanced_settings | Off | Opens the analysis and filter-bank settings dialog. |
| Draw_visualization | On | Draws the diagnostic Picture display. |
| Play_result | On | Plays the final Sound after processing. |
Presets
The presets change only specific controls. Mix, Output_gain_dB, the band count/range, the time-analysis settings, and most other Advanced settings remain as chosen by the user.
| Preset | Values replaced by the preset |
|---|---|
| Gentle | Threshold 4 dB; max reduction 4 dB; Sharpness 0.3; Attack 15 ms; Release 120 ms; smoothing bandwidth 500 Hz; LF protect 200 Hz / 0.8. |
| Moderate | Threshold 3 dB; max reduction 6 dB; Sharpness 0.5; Attack 10 ms; Release 80 ms; smoothing bandwidth 400 Hz; LF protect 150 Hz / 0.7. |
| Aggressive | Threshold 1.5 dB; max reduction 12 dB; Sharpness 0.6; Attack 5 ms; Release 60 ms; smoothing bandwidth 300 Hz; LF protect 120 Hz / 0.5. |
| Vocal Clarity | Threshold 2.5 dB; max reduction 8 dB; Sharpness 0.7; Attack 8 ms; Release 70 ms; smoothing bandwidth 350 Hz; LF protect 250 Hz / 0.9; HF soft 12 kHz. |
| De-Harsh | Threshold 2 dB; max reduction 10 dB; Sharpness 0.5; Attack 8 ms; Release 90 ms; smoothing bandwidth 400 Hz; LF protect 200 Hz / 0.8; HF soft 8 kHz. |
| Custom | No preset values are substituted. |
Advanced settings
| Setting | Default | Meaning |
|---|---|---|
| Window_length_s | 0.030 | Controls the Praat Intensity analysis window. The script clamps it to 10–100 ms and may shorten it automatically for very short sounds. |
| Time_step_s | 0.010 | Requested spacing between analysis frames. It is clamped to 2–50 ms and may be shortened for short sounds. |
| Smoothing_span | Hz | Chooses how neighboring frequency bands are selected for the local baseline: an absolute Hz span or a constant span in octaves. |
| Smoothing_bandwidth_Hz | 400 | Requested baseline span in Hz mode. Because the filter bank is logarithmic, sparse high-frequency bands can make the actual span wider than this value. |
| Smoothing_width_octaves | 1.0 | Baseline width in octave mode; this keeps the relative span more consistent across registers. |
| HF_soft_Hz | 10000 | Above this frequency, the amount of suppression is progressively reduced toward the top of the processing range. |
| Number_of_bands | 24 | Number of logarithmically spaced bands. Allowed range after clamping: 8–64. More bands give finer frequency resolution but require more processing. |
| Min_band_Hz | 60 | Lower edge of the processed filter-bank range; clamped to at least 20 Hz. |
| Max_frequency_Hz | 16000 | Upper edge of the filter-bank range. It is limited to 100 Hz below Nyquist and must remain above Min_band_Hz. |
| Show_spectrum | On | When visualization is enabled, shows the original/processed spectrum in the headline panel. Off replaces that panel with a parameter report. |
How the processing works
Signal flow
Sound → log-spaced bands → band-level analysis → local spectral baseline → resonance score → attack/release smoothing → time-varying band gains → recombination → dry/wet mix → output gain
1. Split the sound into frequency bands
The selected frequency range is divided into logarithmically spaced Hann-bandpass regions. At the default settings there are about three bands per octave.
2. Measure each band over time
Each band is analyzed with Praat Intensity. These values are in dB SPL. For every time frame, the script averages the neighboring band values in dB to form a local baseline.
3. Decide which bands stand out
A band is considered active when its level exceeds the local baseline by more than Threshold_dB. Sharpness then reduces the contribution of weaker candidates relative to the strongest candidate in that frame. It changes the distribution of reduction across bands, not the width of the bands themselves.
4. Protect frequency regions and smooth the motion
Low-frequency protection reduces the amount of attenuation below Protect_Hz. HF_soft_Hz gradually weakens attenuation above its selected frequency. Separate attack and release followers smooth the requested gain reduction through time.
5. Reconstruct the signal
The time-varying gains are resampled to the audio sample rate and applied to the corresponding bands. The script also keeps a residual component outside and between the analyzed bands, so when every band gain is 1 the reconstruction returns the input rather than turning the whole result into a fixed band-pass signal.
Channels & output
- Channels: mono, stereo, and higher channel counts are preserved. Each channel is analyzed and processed independently.
- Duration: preserved.
- Sample rate: preserved.
- Time domain: a source whose start time is not zero is returned to its original start time.
- Output name:
<source>_SootheLike_<preset>, for examplevoice_SootheLike_Moderate. - Level behavior: there is no unconditional peak normalization. After Mix and Output_gain_dB, a clip guard acts only if the peak exceeds 1.0; in that case the final Sound is scaled to a peak of 0.95.
Visualization
The visualization is a diagnostic summary of the original and processed Sounds. Multichannel files are converted to mono for display only; the audio processing itself keeps all channels.
| Panel | What it shows |
|---|---|
| Spectrum / parameter report | With Show_spectrum on: original and processed spectra. With it off: the current detection, suppression, protection, and mix settings. |
| Difference signal | original - processed. This is the complete output difference, not a pure “resonance-only” signal; it also reflects Mix, Output_gain_dB, and any clip-guard scaling. |
| First 500 ms | Original and processed waveforms overlaid on one shared amplitude scale for that zoomed region. |
| Full waveform | Original and processed waveforms overlaid using a shared scale based on the larger peak of the two. |
| Summary strip | Preset, band count, depth, threshold, attack/release, measured peak and average active reduction, active-frame percentage, Mix, output gain, duration, peak, and spectrum status. |
Further Reading
- Zölzer, U. (Ed.). (2011). DAFX: Digital Audio Effects, 2nd ed. Wiley — especially the material on filters, dynamic processing, and spectral processing.
- Smith, J. O. (2011). Spectral Audio Signal Processing. W3K Publishing.
- Oeksound. soothe2 manual — useful for understanding the broader idea of dynamic resonance suppression that inspired this tool; its proprietary algorithm and parameter behavior are not the same as this implementation.