Constants¶
Constant settings.
Settings that should not be modified easily within the scope of this project. There are three categories of the setting:
Feature
Datasets
Midi
Feature¶
Records the settings of the feature extraction process. There are also default settings that can be adjusted, and are records in defaults/*.yaml files.
Some constant feature settings.
- omnizart.constants.feature.CHORD_INT_MAPPING = {'A#:maj': 10, 'A#:min': 22, 'A:maj': 9, 'A:min': 21, 'B:maj': 11, 'B:min': 23, 'C#:maj': 1, 'C#:min': 13, 'C:maj': 0, 'C:min': 12, 'D#:maj': 3, 'D#:min': 15, 'D:maj': 2, 'D:min': 14, 'E:maj': 4, 'E:min': 16, 'F#:maj': 6, 'F#:min': 18, 'F:maj': 5, 'F:min': 17, 'G#:maj': 8, 'G#:min': 20, 'G:maj': 7, 'G:min': 19, 'N': 24, 'X': 25}¶
Mapping of chord names to integers (for
chord
module).
- omnizart.constants.feature.ENHARMONIC_TABLE = {'Ab': 'G#', 'Bb': 'A#', 'Cb': 'B', 'Db': 'C#', 'Eb': 'D#', 'Fb': 'E', 'Gb': 'F#'}¶
Table of major chord to corresponding enharmonic chord (for
chord
module)
- omnizart.constants.feature.FEATURE_NAME_TO_NUMBER = {'C': 3, 'Ceps': 3, 'G': 2, 'GCoS': 2, 'S': 1, 'Spec': 1}¶
Feature name to channel number mapping (for
music
module)
- omnizart.constants.feature.NOTE_PRIORITY_ARRAY = [2.0364304, 1.4848346, 0.5027617, 0.5768271, 2.8335114, 0.733738, 0.83764803, 0.5139924, 0.4998506, 0.4733462, 0.5940674, 0.7641602, 1.148832]¶
Weighting factor for different drum notes (for
drum
module).
Datasets¶
Records the directory structure of each dataset, and will be used for extracting the feature of the whole dataset (not yet supported…).
Information about each dataset.
Supports an easy way to deal with complex folder structure of different datasets in a consice interface. Partial support for downloading public datasets.
Complete information of supported datasets are as following:
Dataset |
Downloadable |
Dataset |
Downloadable |
---|---|---|---|
Maps |
BPS-FH |
O |
|
MusicNet |
O |
MIR-1K |
O |
Maestro |
O |
CMedia |
|
Pop |
Tonas |
||
Ext-Su |
O |
MedleyDB |
|
BillBoard |
O |
- class omnizart.constants.datasets.BaseStructure¶
Bases:
object
Defines the necessary attributes and common functions for each sub-dataset structure class.
All sub-dataset structure class should inherit this base class to ensure the necessary attributes and methods are overriden.
- Attributes
- label_ext
- test_labels
- test_wavs
- train_labels
- train_wavs
- url
Methods
download
([save_path])Download the dataset.
get_test_data_pair
(dataset_path)Get pair of testing file and the coressponding label file path.
get_test_labels
(dataset_path)Get list of complete test label paths
get_test_wavs
(dataset_path)Get list of complete test wav paths
get_train_data_pair
(dataset_path)Get pair of training file and the coressponding label file path.
get_train_labels
(dataset_path)Get list of complete train label paths
get_train_wavs
(dataset_path)Get list of complete train wav paths
load_label
(label_path)Load and parse labels for the given label file path.
- classmethod download(save_path='./')¶
Download the dataset.
After download the compressed (zipped) dataset file, the function will automatically decompress it and delete the original zipped file.
You can apply some post process after download by overriding the function
_post_download
. The _post_download function receives a singledataset_path
as the parameter, and you can do anything to the dataset such as re-organize the directory structure, or filter out some files.
- classmethod get_test_data_pair(dataset_path)¶
Get pair of testing file and the coressponding label file path.
- classmethod get_test_labels(dataset_path)¶
Get list of complete test label paths
- classmethod get_test_wavs(dataset_path)¶
Get list of complete test wav paths
- classmethod get_train_data_pair(dataset_path)¶
Get pair of training file and the coressponding label file path.
- classmethod get_train_labels(dataset_path)¶
Get list of complete train label paths
- classmethod get_train_wavs(dataset_path)¶
Get list of complete train wav paths
- label_ext = None¶
The extension of ground-truth files (e.g. .mid, .csv).
- classmethod load_label(label_path)¶
Load and parse labels for the given label file path.
Parses different format of label information to shared intermediate format, encapslated with
Label
instances. The default is parsing MIDI file format.
- test_labels = None¶
Records folders that contains testing labels.
Similar to the train_labels function, records information of where the corresponding ground-truth files are stored.
- test_wavs = None¶
Record folders that contain testing wav files.
Same as what train_wavs does, but for testing wav files.
- train_labels = None¶
Record folders that contains training labels.
Similar to the train_wavs function, records information of where the corresponding ground-truth files are stored.
- train_wavs = None¶
Record folders that contain trainig wav files.
The path to sub-folders should be the relative path to root folder of the dataset.
Examples
Assume the structure of the dataset looks like following
maps├── MAPS_AkPnCGdD_2│ └── AkPnCGdD└── MAPS_AkPnBcht_2└── AkPnBchtwhere
AkPnCGdD
andAkPnBcht
are the folders that store the wav files. The function should then return a list like:>>> [‘MAPS_AkPnCGdD_2/AkPnCGdD’, ‘MAPS_AkPnBcht_2/AkPnBcht’]
- url = None¶
The URL for downloading the dataset.
- class omnizart.constants.datasets.BeethovenSonatasStructure¶
Bases:
omnizart.constants.datasets.BaseStructure
Constant settings of BPS-FH dataset
- url = 'https://drive.google.com/uc?export=download&id=1nYq2FB5LQfYJoXyYZl3XcklpJkCOnwhV'¶
Hosted dataset download url.
- class omnizart.constants.datasets.CMediaStructure¶
Bases:
omnizart.constants.datasets.BaseStructure
Constant settings of CMedia dataset.
Methods
load_label
(label_path)Load and parse labels for the given label file path.
- label_ext = '.csv'¶
Label extension
- classmethod load_label(label_path)¶
Load and parse labels for the given label file path.
Parses different format of label information to shared intermediate format, encapslated with
Label
instances. The default is parsing MIDI file format.
- test_labels = []¶
Folder to test labels
- test_wavs = []¶
Folder to test wavs
- train_labels = ['train_labels']¶
Folder to train labels
- train_wavs = ['train_data']¶
Folder to train wavs
- url = 'https://drive.google.com/uc?export=download&id=15b298vSP9cPP8qARQwa2X_0dbzl6_Eu7'¶
Official download url provided by MIREX.
- class omnizart.constants.datasets.ExtSuStructure¶
Bases:
omnizart.constants.datasets.BaseStructure
Structure of Extended-Su dataset
- label_ext = '.mid'¶
Label extension
- test_labels = ['1 Tchaikovsky', '2 schumann', '3 beethoven', '5 Mozart', 'PQ01_Dvorak', 'PQ02_Elgar', 'PQ03_Farranc', 'PQ04_Frank', 'PQ05_Hummel', 'PQ06_Schostakovich', 'PQ07_Schubert', 'PQ08_Schubert', 'SQ01_Beethoven', 'SQ02_Janacek', 'SQ03_Schubert', 'SQ04_Janacek', 'SQ04_Ravel', 'SQ05_Mozart', 'SQ07_Haydn', 'SQ08_Dvorak', 'SQ09_Ravel', 'SY06_Mahler', 'VS01_Schumann', 'VS02_Brahms', 'VS03_Debussy', 'VS04_Franck', 'VS05_Mozart', 'WQ01_Nielsen', 'WQ02_Schoenberg', 'WQ03_Cambini', 'WQ04_Danzi']¶
Folder to test labels
- test_wavs = ['1 Tchaikovsky', '2 schumann', '3 beethoven', '5 Mozart', 'PQ01_Dvorak', 'PQ02_Elgar', 'PQ03_Farranc', 'PQ04_Frank', 'PQ05_Hummel', 'PQ06_Schostakovich', 'PQ07_Schubert', 'PQ08_Schubert', 'SQ01_Beethoven', 'SQ02_Janacek', 'SQ03_Schubert', 'SQ04_Janacek', 'SQ04_Ravel', 'SQ05_Mozart', 'SQ07_Haydn', 'SQ08_Dvorak', 'SQ09_Ravel', 'SY06_Mahler', 'VS01_Schumann', 'VS02_Brahms', 'VS03_Debussy', 'VS04_Franck', 'VS05_Mozart', 'WQ01_Nielsen', 'WQ02_Schoenberg', 'WQ03_Cambini', 'WQ04_Danzi']¶
Folder to test wavs
- train_labels = []¶
Folder to train labels
- train_wavs = []¶
Folder to train wavs
- url = 'https://drive.google.com/uc?export=download&id=1Miw9G2O1Y8g253RQ2uQ4udM5XMKB-9p8'¶
Dataset URL
- class omnizart.constants.datasets.MIR1KStructure¶
Bases:
omnizart.constants.datasets.BaseStructure
Constant settings of MIR-1K dataset.
Methods
load_label
(label_path)Load and parse labels for the given label file path.
- label_ext = '.pv'¶
Label extension
- classmethod load_label(label_path)¶
Load and parse labels for the given label file path.
Parses different format of label information to shared intermediate format, encapslated with
Label
instances. The default is parsing MIDI file format.
- percent_train = 0.88¶
Percentage of training data to be partitioned.
- test_labels = ['PitchLabel']¶
Folder to test labels
- test_wavs = ['test_data']¶
Folder to test wavs
- train_labels = ['PitchLabel']¶
Folder to train labels
- train_wavs = ['train_data']¶
Folder to train wavs
- url = 'http://mirlab.org/dataset/public/MIR-1K.zip'¶
Download url of MIR-1K dataset
- class omnizart.constants.datasets.MaestroStructure¶
Bases:
omnizart.constants.datasets.BaseStructure
Structure of Maestro dataset
- label_ext = '.midi'¶
Label extension
- test_labels = ['2018']¶
Folder to test labels
- test_wavs = ['2018']¶
Folder to test wavs
- train_labels = ['2004', '2006', '2008', '2009', '2011', '2013', '2014', '2015', '2017']¶
Folder to train labels
- train_wavs = ['2004', '2006', '2008', '2009', '2011', '2013', '2014', '2015', '2017']¶
Folder to train wavs
- url = 'https://storage.googleapis.com/magentadata/datasets/maestro/v2.0.0/maestro-v2.0.0.zip'¶
Dataset URL
- class omnizart.constants.datasets.MapsStructure¶
Bases:
omnizart.constants.datasets.BaseStructure
Structure of MAPS dataset
Methods
load_label
(label_path)Load and parse labels for the given label file path.
- label_ext = '.txt'¶
Label extension
- classmethod load_label(label_path)¶
Load and parse labels for the given label file path.
Parses different format of label information to shared intermediate format, encapslated with
Label
instances. The default is parsing MIDI file format.
- test_labels = ['MAPS_ENSTDkAm_2/ENSTDkAm/MUS', 'MAPS_ENSTDkCl_2/ENSTDkCl/MUS']¶
Folder to test labels
- test_wavs = ['MAPS_ENSTDkAm_2/ENSTDkAm/MUS', 'MAPS_ENSTDkCl_2/ENSTDkCl/MUS']¶
Folder to test wavs
- train_labels = ['MAPS_AkPnBcht_2/AkPnBcht/MUS', 'MAPS_AkPnBsdf_2/AkPnBsdf/MUS', 'MAPS_AkPnStgb_2/AkPnStgb/MUS', 'MAPS_AkPnCGdD_2/AkPnCGdD/MUS', 'MAPS_SptkBGCl_2/SptKBGCl/MUS', 'MAPS_StbgTGd2_2/StbgTGd2/MUS']¶
Folder to train labels
- train_wavs = ['MAPS_AkPnBcht_2/AkPnBcht/MUS', 'MAPS_AkPnBsdf_2/AkPnBsdf/MUS', 'MAPS_AkPnStgb_2/AkPnStgb/MUS', 'MAPS_AkPnCGdD_2/AkPnCGdD/MUS', 'MAPS_SptkBGCl_2/SptKBGCl/MUS', 'MAPS_StbgTGd2_2/StbgTGd2/MUS']¶
Folder to train wavs
- class omnizart.constants.datasets.McGillBillBoard¶
Bases:
omnizart.constants.datasets.BaseStructure
Constant settings of McGill BillBoard dataset.
Methods
get_test_labels
(dataset_path)Get list of complete test label paths
get_test_wavs
(dataset_path)Get list of complete test wav paths
get_train_labels
(dataset_path)Get list of complete train label paths
get_train_wavs
(dataset_path)Get list of complete train wav paths
- feature_file_name = 'bothchroma.csv'¶
Name of feature files
- feature_folder = './McGill-Billboard-Features'¶
Path to the feature folder relative to dataset
- classmethod get_test_labels(dataset_path)¶
Get list of complete test label paths
- classmethod get_test_wavs(dataset_path)¶
Get list of complete test wav paths
- classmethod get_train_labels(dataset_path)¶
Get list of complete train label paths
- classmethod get_train_wavs(dataset_path)¶
Get list of complete train wav paths
- ignore_ids = [353, 634, 1106]¶
File IDs to be ignored
- index_file_path = './billboard-2.0-index.csv'¶
Path to the index file relative the dataset
- label_file_name = 'majmin.lab'¶
Name of label files
- label_folder = './McGill-Billboard-MIREX'¶
Path to the label folder relative to dataset
- train_test_split_id = 1000¶
Split ID of train/test set.
- url = 'https://drive.google.com/uc?export=download&id=1_K_Fof4zt1IQvs1aDmf-5wY0wHqgcPlC'¶
Dataset URL
- class omnizart.constants.datasets.MedleyDBStructure¶
Bases:
omnizart.constants.datasets.BaseStructure
Constant settings of MedleyDB dataset.
Notice here that current design of the structure is for getting vocal melody ground-truth files only. All other tracks are ignored when calling to
get_train_data_pair
orget_test_data_pair
.Methods
get_test_labels
(dataset_path)Get list of complete test label paths
get_train_labels
(dataset_path)Get list of complete train label paths
load_label
(label_path)Load and parse labels for the given label file path.
- classmethod get_test_labels(dataset_path)¶
Get list of complete test label paths
- classmethod get_train_labels(dataset_path)¶
Get list of complete train label paths
- label_ext = '.csv'¶
Extension of pitch label files.
- label_postfix = '_STEM_{track_num}'¶
Postfix of pitch label files. Can be formatted with
label_postfix.format(track_num=...)
.
- classmethod load_label(label_path)¶
Load and parse labels for the given label file path.
Parses different format of label information to shared intermediate format, encapslated with
Label
instances. The default is parsing MIDI file format.
- meta_file_postfix = '_METADATA.yaml'¶
Postfix of meta files.
- pitch_annotation_folder = 'Annotations/Pitch_Annotations'¶
Folder to pitch-related ground truth files. The reason to define another variable for holding the same content as
train_labels
is to keep the flexibility for extending the ability getting other kinds of ground-truth files such as guitar tracks or bass tracks.
- test_labels = ['Annotations/Pitch_Annotations']¶
Folder to test label files
- test_wavs = ['Audio/MusicDelta_FunkJazz', 'Audio/Phoenix_LarkOnTheStrandDrummondCastle', 'Audio/MatthewEntwistle_TheArch', 'Audio/SecretMountains_HighHorse', 'Audio/Snowmine_Curfews', 'Audio/StevenClark_Bounty', 'Audio/TablaBreakbeatScience_Animoog', 'Audio/ClaraBerryAndWooldog_AirTraffic', 'Audio/MusicDelta_Rockabilly', 'Audio/JoelHelander_Definition']¶
Folder to test wavs
- train_labels = ['Annotations/Pitch_Annotations']¶
Folder to train label files
- train_wavs = ['Audio/AClassicEducation_NightOwl', 'Audio/AimeeNorwich_Child', 'Audio/AimeeNorwich_Flying', 'Audio/AlexanderRoss_GoodbyeBolero', 'Audio/AlexanderRoss_VelvetCurtain', 'Audio/AmarLal_Rest', 'Audio/AmarLal_SpringDay1', 'Audio/Auctioneer_OurFutureFaces', 'Audio/AvaLuna_Waterduct', 'Audio/BigTroubles_Phantom', 'Audio/BrandonWebster_DontHearAThing', 'Audio/BrandonWebster_YesSirICanFly', 'Audio/CelestialShore_DieForUs', 'Audio/ChrisJacoby_BoothShotLincoln', 'Audio/ClaraBerryAndWooldog_Boys', 'Audio/ClaraBerryAndWooldog_Stella', 'Audio/ClaraBerryAndWooldog_TheBadGuys', 'Audio/ClaraBerryAndWooldog_WaltzForMyVictims', 'Audio/Creepoid_OldTree', 'Audio/CroqueMadame_Oil', 'Audio/CroqueMadame_Pilot', 'Audio/Debussy_LenfantProdigue', 'Audio/DreamersOfTheGhetto_HeavyLove', 'Audio/EthanHein_1930sSynthAndUprightBass', 'Audio/EthanHein_BluesForNofi', 'Audio/EthanHein_GirlOnABridge', 'Audio/EthanHein_HarmonicaFigure', 'Audio/FamilyBand_Again', 'Audio/Grants_PunchDrunk', 'Audio/Handel_TornamiAVagheggiar', 'Audio/HeladoNegro_MitadDelMundo', 'Audio/HezekiahJones_BorrowedHeart', 'Audio/HopAlong_SisterCities', 'Audio/InvisibleFamiliars_DisturbingWildlife', 'Audio/JoelHelander_ExcessiveResistancetoChange', 'Audio/JoelHelander_IntheAtticBedroom', 'Audio/KarimDouaidy_Hopscotch', 'Audio/KarimDouaidy_Yatora', 'Audio/LizNelson_Coldwar', 'Audio/LizNelson_ImComingHome', 'Audio/LizNelson_Rainfall', 'Audio/MatthewEntwistle_AnEveningWithOliver', 'Audio/MatthewEntwistle_DontYouEver', 'Audio/MatthewEntwistle_FairerHopes', 'Audio/MatthewEntwistle_ImpressionsOfSaturn', 'Audio/MatthewEntwistle_Lontano', 'Audio/MatthewEntwistle_TheFlaxenField', 'Audio/Meaxic_TakeAStep', 'Audio/Meaxic_YouListen', 'Audio/MichaelKropf_AllGoodThings', 'Audio/Mozart_BesterJungling', 'Audio/Mozart_DiesBildnis', 'Audio/MusicDelta_80sRock', 'Audio/MusicDelta_Beatles', 'Audio/MusicDelta_BebopJazz', 'Audio/ChrisJacoby_PigsFoot', 'Audio/FacesOnFilm_WaitingForGa', 'Audio/Lushlife_ToynbeeSuite', 'Audio/MusicDelta_Beethoven', 'Audio/MusicDelta_Grunge', 'Audio/Phoenix_BrokenPledgeChicagoReel', 'Audio/MusicDelta_Britpop', 'Audio/MusicDelta_ChineseChaoZhou', 'Audio/MusicDelta_ChineseDrama', 'Audio/MusicDelta_ChineseHenan', 'Audio/MusicDelta_ChineseJiangNan', 'Audio/MusicDelta_ChineseXinJing', 'Audio/MusicDelta_ChineseYaoZu', 'Audio/MusicDelta_CoolJazz', 'Audio/MusicDelta_Country1', 'Audio/MusicDelta_Country2', 'Audio/MusicDelta_Disco', 'Audio/MusicDelta_FreeJazz', 'Audio/MusicDelta_FusionJazz', 'Audio/MusicDelta_Gospel', 'Audio/MusicDelta_GriegTrolltog', 'Audio/MusicDelta_Hendrix', 'Audio/MusicDelta_InTheHalloftheMountainKing', 'Audio/MusicDelta_LatinJazz', 'Audio/MusicDelta_ModalJazz', 'Audio/MusicDelta_Pachelbel', 'Audio/MusicDelta_Punk', 'Audio/MusicDelta_Reggae', 'Audio/MusicDelta_Rock', 'Audio/MusicDelta_Shadows', 'Audio/MusicDelta_SpeedMetal', 'Audio/MusicDelta_SwingJazz', 'Audio/MusicDelta_Vivaldi', 'Audio/MusicDelta_Zeppelin', 'Audio/NightPanther_Fire', 'Audio/Phoenix_ColliersDaughter', 'Audio/Phoenix_ElzicsFarewell', 'Audio/Phoenix_ScotchMorris', 'Audio/Phoenix_SeanCaughlinsTheScartaglen', 'Audio/PortStWillow_StayEven', 'Audio/PurlingHiss_Lolita', 'Audio/Schubert_Erstarrung', 'Audio/Schumann_Mignon', 'Audio/StrandOfOaks_Spacestation', 'Audio/SweetLights_YouLetMeDown', 'Audio/TablaBreakbeatScience_CaptainSky', 'Audio/TablaBreakbeatScience_MiloVsMongo', 'Audio/TablaBreakbeatScience_MoodyPlucks', 'Audio/TablaBreakbeatScience_PhaseTransition', 'Audio/TablaBreakbeatScience_RockSteady', 'Audio/TablaBreakbeatScience_Scorpio', 'Audio/TablaBreakbeatScience_Vger', 'Audio/TablaBreakbeatScience_WhoIsIt', 'Audio/TheDistricts_Vermont', 'Audio/TheScarletBrand_LesFleursDuMal', 'Audio/TheSoSoGlos_Emergency', 'Audio/Wolf_DieBekherte']¶
Folder to train wavs
- wav_postfix = '_MIX'¶
Postfix of wav files.
- class omnizart.constants.datasets.MusicNetStructure¶
Bases:
omnizart.constants.datasets.BaseStructure
Structure of MusicNet dataset
Methods
load_label
(label_path)Load and parse labels for the given label file path.
- label_ext = '.csv'¶
Label extension
- classmethod load_label(label_path)¶
Load and parse labels for the given label file path.
Parses different format of label information to shared intermediate format, encapslated with
Label
instances. The default is parsing MIDI file format.
- test_labels = ['test_labels']¶
Folder to test labels
- test_wavs = ['test_data']¶
Folder to test wavs
- train_labels = ['train_labels']¶
Folder to train labels
- train_wavs = ['train_data']¶
Folder to train wavs
- url = 'https://homes.cs.washington.edu/~thickstn/media/musicnet.tar.gz'¶
Dataset URL
- class omnizart.constants.datasets.PopStructure¶
Bases:
omnizart.constants.datasets.BaseStructure
Structure of Pop dataset
- label_ext = '.mid'¶
Label extension
- test_labels = ['05_align_mid/dist0p30']¶
Folder to test labels
- test_wavs = ['01_ytd_audio/dist0p30']¶
Folder to test wavs
- train_labels = ['05_align_mid/dist0p00', '05_align_mid/dist0p10', '05_align_mid/dist0p20', '05_align_mid/dist0p40', '05_align_mid/dist0p50', '05_align_mid/dist0p60']¶
Folder to train labels
- train_wavs = ['01_ytd_audio/dist0p00', '01_ytd_audio/dist0p10', '01_ytd_audio/dist0p20', '01_ytd_audio/dist0p40', '01_ytd_audio/dist0p50', '01_ytd_audio/dist0p60']¶
Folder to train wavs
- class omnizart.constants.datasets.TonasStructure¶
Bases:
omnizart.constants.datasets.BaseStructure
Constant settings of TONAS dataset.
- Attributes
- url
Methods
load_label
(label_path)Load and parse labels for the given label file path.
- label_ext = '.notes.Corrected'¶
Label extension for note-level transcription.
- label_f0_ext = '.f0.Corrected'¶
Label extension for f0 contour transcription.
- classmethod load_label(label_path)¶
Load and parse labels for the given label file path.
Parses different format of label information to shared intermediate format, encapslated with
Label
instances. The default is parsing MIDI file format.
- test_labels = []¶
Folder to test labels
- test_wavs = []¶
Folder to test wavs
- train_labels = ['Deblas', 'Martinetes1', 'Martinetes2']¶
Folder to train labels
- train_wavs = ['Deblas', 'Martinetes1', 'Martinetes2']¶
Folder to train wavs
- url = None¶
The dataset is not made public. You have to ask for the access from zenodo: https://zenodo.org/record/1290722
Midi¶
Records MIDI related settings, including mapping of program number and the corresponding instrument name.
Stores MIDI-related constant variables.
- omnizart.constants.midi.MIDI_PROGRAM_NAME_MAPPING = {'0': 'Acoustic Grand Piano', '1': 'Bright Acoustic Piano', '10': 'Music Box', '100': 'FX 5 (brightness)', '101': 'FX 6 (goblins)', '102': 'FX 7 (echoes)', '103': 'FX 8 (sci-fi)', '104': 'Sitar', '105': 'Banjo', '106': 'Shamisen', '107': 'Koto', '108': 'Kalimba', '109': 'Bag pipe', '11': 'Vibraphone', '110': 'Fiddle', '111': 'Shanai', '112': 'Tinkle Bell', '113': 'Agogo', '114': 'Steel Drums', '115': 'Woodblock', '116': 'Taiko Drum', '117': 'Melodic Tom', '118': 'Synth Drum', '119': 'Reverse Cymbal', '12': 'Marimba', '120': 'Guitar Fret Noise', '121': 'Breath Noise', '122': 'Seashore', '123': 'Bird Tweet', '124': 'Telephone Ring', '125': 'Helicopter', '126': 'Applause', '127': 'Gunshot', '13': 'Xylophone', '14': 'Tubular Bells', '15': 'Dulcimer', '16': 'Drawbar Organ', '17': 'Percussive Organ', '18': 'Rock Organ', '19': 'Church Organ', '2': 'Electric Grand Piano', '20': 'Reed Organ', '21': 'Accordion', '22': 'Harmonica', '23': 'Tango Accordion', '24': 'Acoustic Guitar (nylon)', '25': 'Acoustic Guitar (steel)', '26': 'Electric Guitar (jazz)', '27': 'Electric Guitar (clean)', '28': 'Electric Guitar (muted)', '29': 'Overdriven Guitar', '3': 'Honky-tonk Piano', '30': 'Distortion Guitar', '31': 'Guitar Harmonics', '32': 'Acoustic Bass', '33': 'Electric Bass (finger)', '34': 'Electric Bass (pick)', '35': 'Retless Bass', '36': 'Slap Bass 1', '37': 'Slap Bass 2', '38': 'Synth Bass 1', '39': 'Synth Bass 2', '4': 'Electric Piano 1', '40': 'Violin', '41': 'Viola', '42': 'Cello', '43': 'Contrabass', '44': 'Tremolo Strings', '45': 'Pizzicato Strings', '46': 'Orchestral Harp', '47': 'Timpani', '48': 'String Ensemble 1', '49': 'String Ensemble 2', '5': 'Electric Piano 2', '50': 'Synth Strings 1', '51': 'Synth Strings 2', '52': 'Choir Aahs', '53': 'Voice Oohs', '54': 'Synth Voice', '55': 'Orchestra Hit', '56': 'Trumpet', '57': 'Trombone', '58': 'Tuba', '59': 'Muted Trumpet', '6': 'Harpsichord', '60': 'French Horn', '61': 'Brass Section', '62': 'Synth Brass 1', '63': 'Synth Brass 2', '64': 'Soprano Sax', '65': 'Alto Sax', '66': 'Tenor Sax', '67': 'Baritone Sax', '68': 'Oboe', '69': 'English Horn', '7': 'Clavi', '70': 'Bassoon', '71': 'Clarinet', '72': 'Piccolo', '73': 'Flute', '74': 'Recorder', '75': 'Pan Flute', '76': 'Blown Bottle', '77': 'Shakuhachi', '78': 'Whistle', '79': 'Ocarina', '8': 'Celesta', '80': 'Lead 1 (square)', '81': 'Lead 2 (sawtooth)', '82': 'Lead 3 (calliope)', '83': 'Lead 4 (chiff)', '84': 'Lead 5 (charang)', '85': 'Lead 6 (voice)', '86': 'Lead 7 (fifths)', '87': 'Lead 8 (bass+lead)', '88': 'Pad 1 (new age)', '89': 'Pad 2 (warm)', '9': 'Glockenspiel', '90': 'Pad 3 (polysynth)', '91': 'Pad 4 (choir)', '92': 'Pad 5 (bowed)', '93': 'Pad 6 (metallic)', '94': 'Pad 7 (halo)', '95': 'Pad 8 (sweep)', '96': 'FX 1 (rain)', '97': 'FX 2 (soundtrack)', '98': 'FX 3 (crystal)', '99': 'FX 4 (atmosphere)'}¶
Mappings of MIDI program number and the corresponding name derived from the Wiki page: https://en.wikipedia.org/wiki/General_MIDI
- omnizart.constants.midi.MUSICNET_INSTRUMENT_PROGRAMS = [0, 6, 40, 41, 42, 43, 60, 68, 70, 71, 73]¶
Program numbers that are used in MusicNet dataset.
- omnizart.constants.midi.POP_INSTRUMENT_PROGRAMES = [24, 32, 40, 0, 56]¶
Program numbers that represent different groups of channels used in Pop dataset. Guitar, bass, strings, organ, piano, and others
- omnizart.constants.midi.SOUNDFONT_PATH = '/home/runner/work/omnizart/omnizart/omnizart/resource/soundfonts.sf2'¶
Path to the soundfont.