Skip to content

plaura10/env-soundnet

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

129 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🔊 Spiking Neural Networks for Environmental Sound Classification

This project explores Spiking Neural Networks (SNNs) for environmental sound classification using the ESC-10 dataset.
Multiple spike encoding strategies and SNN architectures are implemented and benchmarked with PyTorch + snnTorch.


📁 Project Structure

  • preprocessing.py 🎧
    Audio loading and preprocessing: log-Mel spectrograms, normalization, padding and data augmentation.

  • spike_encoding.py
    Dataset classes implementing different spike encodings:

    • Delta Modulation
    • Threshold Adaptive Encoding (TAE)
    • Step Forward Encoding
  • models.py 🧠
    Spiking neural architectures:

    • Fully-connected SNN (SNNClassifier)
    • Convolutional SNN (C_SNN)
  • train_eval.py 📊
    Training loop and evaluation utilities (accuracy, F1-score, confusion matrices).

  • env-soundnet.ipynb 🚀
    End-to-end notebook to run preprocessing, training and evaluation
    (main entry point).


🧩 Requirements

Install the required dependencies

🎼 Dataset

The project uses the ESC-10 dataset, organized by class as follows. Each folder contains the corresponding .wav audio files.

▶️ How to Run

  1. Open env-soundnet.ipynb (recommended: Google Colab ☁️)
  2. Configure the dataset path
  3. Run the notebook cells sequentially to:
    • load and preprocess audio data 🎧
    • apply spike encoding strategies ⚡
    • train SNN and Conv-SNN models 🧠
    • evaluate performance and analyze results 📊

Trained models are automatically saved to disk 💾.


✨ Notes

  • The modular design allows easy experimentation with different spike encodings and network architectures.
  • Spike trains and neural activity can be visualized using the provided analysis utilities 📈.

About

Deep Learning project for environmental sound classification

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Jupyter Notebook 99.7%
  • Python 0.3%