SonicCaption ESC-50 CNN (10 classes)

Compact CNN that classifies short audio windows into 10 environmental sound classes. Trained by the SonicCaption team (MAI522-5 Speech Processing & Recognition) to add non-speech events such as [Applause] or [Door knock] to captions.

Classes

clapping, laughing, coughing, sneezing, footsteps, door_wood_knock, glass_breaking, siren, dog, rain

Data

ESC-50 (K. J. Piczak, ESC: Dataset for Environmental Sound Classification, ACM MM 2015), 10-class subset, 40 clips per class, 5 s each. ESC-50 is licensed CC BY-NC 3.0, so this model is for non-commercial use.

Input

16 kHz mono audio → log-Mel spectrogram (64 Mel bands, 400-sample Hann window, 160-sample hop, power→dB with ref 1.0) → normalised with the mean/std in config.json.

Architecture

4 conv blocks ([Conv3×3-BN-ReLU]×2 + MaxPool2), channels 32/64/128/256, global average pooling, Dropout 0.3, linear head.

Training

Adam (lr 0.001, weight decay 0.0001), cosine schedule, 40 epochs, batch 32, best epoch by validation accuracy. Augmentation (training only): random gain, time shift, SpecAugment-style frequency and time masks.

Evaluation

ESC-50 official folds; test fold k, val fold k+1, train on remaining 3; 5 fold(s); clip-level (5 s clips).

Metric Value
Accuracy (out-of-fold) 0.843
Macro precision 0.848
Macro recall 0.843
Macro F1 0.842
Per-fold accuracy 0.843 ± 0.037
Class Precision Recall F1
clapping 0.903 0.700 0.789
laughing 0.861 0.775 0.816
coughing 0.711 0.675 0.692
sneezing 0.686 0.875 0.769
footsteps 0.886 0.775 0.827
door_wood_knock 0.884 0.950 0.916
glass_breaking 0.875 0.875 0.875
siren 0.930 1.000 0.964
dog 0.921 0.875 0.897
rain 0.822 0.925 0.871

The published weights are from the run with test fold 5 (test accuracy 0.875).

Limitations

  • Only 400 training clips; real-world recordings differ from ESC-50 (domain shift).
  • Closed set of 10 classes: any other sound is forced into one of them, so the app applies a confidence threshold.
  • Trained on 5 s clips with one sound each; overlapping sounds and speech-plus-event mixtures are not modelled.
  • Sliding-window timestamps are approximate, not exact event boundaries.
Downloads last month
26
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support