gerard@1: % Copyright 2013 MUSIC TECHNOLOGY GROUP, UNIVERSITAT POMPEU FABRA gerard@1: % gerard@1: % Written by Gerard Roma gerard@1: % gerard@1: % This program is free software: you can redistribute it and/or modify gerard@1: % it under the terms of the GNU Affero General Public License as published by gerard@1: % the Free Software Foundation, either version 3 of the License, or gerard@1: % (at your option) any later version. gerard@1: % gerard@1: % This program is distributed in the hope that it will be useful, gerard@1: % but WITHOUT ANY WARRANTY; without even the implied warranty of gerard@1: % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the gerard@1: % GNU Affero General Public License for more details. gerard@1: % gerard@1: % You should have received a copy of the GNU Affero General Public License gerard@1: % along with this program. If not, see . gerard@1: gerard@1: function [x,y] = get_filenames(dir) gerard@1: classes = {'bus' 'busystreet' 'office' 'openairmarket' 'park' 'quietstreet' 'restaurant' 'supermarket' 'tube' 'tubestation'}; gerard@1: gerard@1: gerard@1: names = []; gerard@1: labels = []; gerard@1: gerard@1: for i=1:length(classes) gerard@1: for j = 1:10 gerard@1: suffix=sprintf('%02d.wav',j); gerard@1: name = strcat(dir,classes(i),suffix); gerard@1: names = [names;name]; gerard@1: labels = [labels; i]; gerard@1: end gerard@1: end gerard@1: x = names; gerard@1: y = labels; gerard@1: end gerard@1: gerard@1: