jordan@1: % This is a script that reproduces the results of the following ISMIR paper: jordan@1: % jordan@1: % Smith, J. B. L., and E. Chew. 2013. A meta-analysis of the MIREX Structural jordan@1: % Segmentation task. Proceedings of the International Society for Music jordan@1: % Information Retrieval Conference. Curitiba, Brazil. 251–6. jordan@1: % jordan@1: % DO read the README.txt before running this file. Among other things, it will jordan@1: % explain that you must download some data and place it in the correct file jordan@1: % tree before this script will work. jordan@1: % jordan@1: % DO read the comments in this script before running it. You may want to run jordan@1: % it piece by piece in order to understand exactly what it is doing. jordan@1: jordan@1: jordan@1: %% jordan@1: % STEP 0: Set up parameters. jordan@1: % Name the MIREX datasets and algorithms desired. jordan@1: dsets = {'mrx09','mrx10_1','mrx10_2','sal'}; jordan@1: algos = {'KSP1','KSP2','KSP3','MHRAF1','OYZS1','SBV1','SMGA1','SMGA2','SP1'}; jordan@1: base_directory = '/Users/jordan/Documents/classes/mirex_data/2012'; jordan@1: base_directory = '/Users/jordan/Desktop/MIREX_data'; jordan@1: % You should get a copy of the evalution scripts in the Code.SoundSoftware jordan@1: % repository. Again, please see the README... jordan@1: addpath('/Users/jordan/Documents/structural_analysis_evaluation') jordan@1: jordan@1: jordan@1: %% jordan@1: % STEP 1: Download data from MIREX website: jordan@1: % jordan@1: % - Ground truth files jordan@1: % - Algorithm output jordan@1: % - Reported evaluation results jordan@1: % (See README.txt to see where to get this data.) jordan@1: jordan@1: jordan@1: %% jordan@1: % STEP 2: Import all this data into some Matlab structures. jordan@1: % jordan@1: % 1. Assemble MIREX ground truth file data in Matlab. jordan@1: [mirex_truth mirex_dset_origin] = collect_all_mirex_annotations(base_directory, dsets, algos); jordan@1: % 2. Assemble MIREX algorithm output data in Matlab. jordan@1: mirex_output = collect_all_mirex_algo_output_data(base_directory, dsets, algos); jordan@1: % 3. Assemble MIREX evaluation results in Matlab. jordan@1: mirex_results = collect_all_mirex_results(base_directory, dsets, algos); jordan@1: % 4. Download public repositories of annotations. jordan@1: % NB: You must do this manually, as per the README. jordan@1: % 5. Assemble public ground truth data in Matlab. jordan@1: [public_truth public_dset_origin] = collect_all_public_annotations(base_directory); jordan@1: jordan@1: jordan@1: %% jordan@1: % STEP 3: Match MIREX and public data. jordan@1: % jordan@1: % With this information, we can now easily search for matches between jordan@1: % MIREX and public ground truth. jordan@1: [pub2mir, mir2pub, P] = match_mirex_to_public_data(mirex_truth, public_truth, mirex_dset_origin, public_dset_origin); jordan@1: % If you have already done this, do not repeat this time-consuming step. Instead: jordan@1: % load match_mirex_to_public_data_results jordan@1: jordan@1: %% jordan@1: % STEP 4: Compile datacubes jordan@1: % 1. Compute extra evaluation measures using MIREX algorithm output. jordan@1: % 2. Compute extra features of the annotations (song length, mean segment length, etc.). jordan@1: % 3. Put it all together in a giant MEGADATACUBE. jordan@1: [datacube newcube extracube indexing_info] = compile_datacubes(mirex_truth, ... jordan@1: mirex_dset_origin, public_truth, mirex_output, mirex_results, mir2pub); jordan@1: % If you have already done this, do not repeat this time-consuming step. Instead: jordan@1: % load datacubes jordan@1: megadatacube = [datacube newcube extracube]; jordan@1: jordan@1: jordan@1: %% jordan@1: % Step 5: Do the statistics! jordan@1: % 1. Compute correlations between all these parameters. jordan@1: % 2. Display correlation figures. jordan@1: % 3. Display analysis result figure. jordan@1: do_correlation_analyses % this one is just a script because it does not return any values. jordan@1: jordan@1: % You are now finished!