- Create a directory called sound_samples. (Path: Physics4BL-Project/sound_samples)
- Download and unzip each instrument zip file
- Run the following command on each instrument directory to move samples that don't match the string called "filter" to another directory:
find . -maxdepth 1 -type f -not -name "*filter*" -exec mv {} /path/to/dir \;
Alternatively, you can remove these unwanted files:
find . -maxdepth 1 -type f -not -name "*filter*" -exec rm -rf {} \;
- Move each instrument directory to the sound_samples folder
- note_classification/note_classification_code.py will now read .wav files from sound_samples directory. (e.g. to read a trumpet sound file, we would read from the path: Physics4BL-Project/sound_samples/trumpet/{name of trumpet file}.wav)
- To run the classification, do:
cd note_classification
python note_classification_code.py
-
pip install sounddevice
or
pip3 install sounddevice
-
cd guitar_tuner
-
python tuner.py