Skip to content

A simple, custom neural network trained on 1,900+ synthetically generated chromagrams to classify Western musical scales.

Notifications You must be signed in to change notification settings

omavashia2005/ChromaLite

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

16 Commits
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🎡 ChromaLite: Neural Network-based Musical Scale Classifier

ChromaLite is a machine learning pipeline for predicting Western musical scales from audio using chromagrams. It includes a custom dataset generator, chroma feature extraction, and a simple neural network built with PyTorch.

Think of it as the underlying system for a β€œShazam for scale detection” β€” trained on music theory data.


πŸ› οΈ Tech Stack

PyTorch Logo NumPy pandas Logo Matplotlib Logo

Music and Audio: Librosa, music21, FluidSynth


πŸ“ Project Highlights

  • πŸ”§ Synthetic Dataset Generator
    Generates labeled chroma tensors for 24 Western scales using music21, librosa, and MIDI-to-audio synthesis.

  • 🎼 1,900+ Samples Across 24 Scales
    Each sample contains randomized notes in a specific scale, saved as chroma tensors and scale indices.

  • 🧠 Custom Neural Network Model (ChromaLite)
    A simple PyTorch-based neural network that learns to classify musical scales from [1, 12, T] chroma inputs.


πŸ”¬ Dataset Overview

  • Input: Chroma tensor [1, 12, T] (12 pitch classes, variable time)
  • Output: Integer scale index (0–23, covering major and minor scales)
  • Format: .pt and .csv versions provided
  • πŸ‘‰ View Dataset on Kaggle

πŸ“ˆ Results

Train Accuracy Test Accuracy
79.1% 78.28%

πŸ”­ Future Work

  • Add rhythmic diversity, chords, and velocity variation
  • Generate more unique samples
  • Build more models

About

A simple, custom neural network trained on 1,900+ synthetically generated chromagrams to classify Western musical scales.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published