changeset 34:0d52ba6844b9

working on chroma inclusion in alignment
author Andrew N Robertson <andrew.robertson@eecs.qmul.ac.uk>
date Tue, 03 Apr 2012 13:13:38 +0100
parents ca40d52d9998
children 6fb77b20413c
files EvaluationPlan.pages MaxPatchToPlayFiles/MultiMatchPlayer3.maxpat src/AudioEventMatcher.cpp src/RecordedMultitrackAudio.cpp
diffstat 4 files changed, 154 insertions(+), 54 deletions(-) [+]
line wrap: on
line diff
Binary file EvaluationPlan.pages has changed
--- a/MaxPatchToPlayFiles/MultiMatchPlayer3.maxpat	Mon Apr 02 18:47:25 2012 +0100
+++ b/MaxPatchToPlayFiles/MultiMatchPlayer3.maxpat	Tue Apr 03 13:13:38 2012 +0100
@@ -20,6 +20,75 @@
 		"devicewidth" : 0.0,
 		"boxes" : [ 			{
 				"box" : 				{
+					"maxclass" : "newobj",
+					"text" : "r seekplay",
+					"patching_rect" : [ 1517.0, 502.0, 62.0, 19.0 ],
+					"id" : "obj-206",
+					"numinlets" : 0,
+					"fontsize" : 10.0,
+					"numoutlets" : 1,
+					"outlettype" : [ "" ],
+					"fontname" : "Verdana"
+				}
+
+			}
+, 			{
+				"box" : 				{
+					"maxclass" : "newobj",
+					"text" : "r seekplay",
+					"patching_rect" : [ 785.0, 284.0, 62.0, 19.0 ],
+					"id" : "obj-205",
+					"numinlets" : 0,
+					"fontsize" : 10.0,
+					"numoutlets" : 1,
+					"outlettype" : [ "" ],
+					"fontname" : "Verdana"
+				}
+
+			}
+, 			{
+				"box" : 				{
+					"maxclass" : "newobj",
+					"text" : "r seekplay",
+					"patching_rect" : [ 493.0, 283.0, 62.0, 19.0 ],
+					"id" : "obj-204",
+					"numinlets" : 0,
+					"fontsize" : 10.0,
+					"numoutlets" : 1,
+					"outlettype" : [ "" ],
+					"fontname" : "Verdana"
+				}
+
+			}
+, 			{
+				"box" : 				{
+					"maxclass" : "newobj",
+					"text" : "r seekplay",
+					"patching_rect" : [ 55.0, 290.0, 62.0, 19.0 ],
+					"id" : "obj-203",
+					"numinlets" : 0,
+					"fontsize" : 10.0,
+					"numoutlets" : 1,
+					"outlettype" : [ "" ],
+					"fontname" : "Verdana"
+				}
+
+			}
+, 			{
+				"box" : 				{
+					"maxclass" : "newobj",
+					"text" : "s seekplay",
+					"patching_rect" : [ 131.0, 120.0, 63.0, 19.0 ],
+					"id" : "obj-202",
+					"numinlets" : 1,
+					"fontsize" : 10.0,
+					"numoutlets" : 0,
+					"fontname" : "Verdana"
+				}
+
+			}
+, 			{
+				"box" : 				{
 					"maxclass" : "comment",
 					"text" : "manual open files",
 					"patching_rect" : [ 673.0, 116.0, 150.0, 19.0 ],
@@ -147,7 +216,7 @@
 , 			{
 				"box" : 				{
 					"maxclass" : "message",
-					"text" : "open Supersaurus:/Gronk/Gronkn/Bounces/MarbleArchMultitracks/Take3/01Bass.wav",
+					"text" : "open \"Supersaurus:/Gronk/Gronkn/Bounces/StationGateMultitracks/TakeOneHalf/Ac D.I.wav\"",
 					"patching_rect" : [ -306.0, 339.0, 783.0, 17.0 ],
 					"id" : "obj-188",
 					"numinlets" : 2,
@@ -252,7 +321,7 @@
 					"numoutlets" : 2,
 					"size" : 12,
 					"outlettype" : [ "", "" ],
-					"presentation_rect" : [ 601.0, 414.0, 270.0, 73.0 ],
+					"presentation_rect" : [ 175.0, 442.0, 270.0, 73.0 ],
 					"setminmax" : [ 0.0, 1.0 ]
 				}
 
@@ -343,17 +412,14 @@
 , 			{
 				"box" : 				{
 					"maxclass" : "message",
-					"text" : "/elec 3 51356.59 1. 0.593515 0.691255 0.595329 0.534706 0.55767 0.7984 0.289442 0.344949 0.212635 0.269108 0.579788",
+					"text" : "/elec 3 11362.032227 0.338361 1. 0.282111 0.236207 0.207194 0.357556 0.883131 0.117726 0.327179 0.222367 0.814479 0.213272",
 					"linecount" : 4,
-					"presentation_linecount" : 2,
 					"patching_rect" : [ 1684.0, 922.0, 223.0, 53.0 ],
-					"presentation" : 1,
 					"id" : "obj-189",
 					"numinlets" : 2,
 					"fontsize" : 10.0,
 					"numoutlets" : 1,
 					"outlettype" : [ "" ],
-					"presentation_rect" : [ 491.0, 339.0, 642.0, 29.0 ],
 					"fontname" : "Verdana"
 				}
 
@@ -397,7 +463,7 @@
 					"fontsize" : 10.0,
 					"numoutlets" : 3,
 					"outlettype" : [ "int", "", "" ],
-					"presentation_rect" : [ 386.0, 338.0, 100.0, 19.0 ],
+					"presentation_rect" : [ 177.0, 334.0, 100.0, 19.0 ],
 					"items" : [ "click", "off", ",", "slope", "detect", ",", "threshold", "detect" ],
 					"fontname" : "Verdana"
 				}
@@ -1563,7 +1629,7 @@
 , 			{
 				"box" : 				{
 					"maxclass" : "message",
-					"text" : "Supersaurus:/Gronk/Gronkn/Bounces/MarbleArchMultitracks/Take3/",
+					"text" : "Supersaurus:/Gronk/Gronkn/Bounces/StationGateMultitracks/TakeOneHalf/",
 					"presentation_linecount" : 2,
 					"patching_rect" : [ 1203.0, -126.0, 469.0, 17.0 ],
 					"presentation" : 1,
@@ -1602,7 +1668,7 @@
 					"fontsize" : 10.0,
 					"numoutlets" : 1,
 					"outlettype" : [ "" ],
-					"presentation_rect" : [ 46.0, 422.0, 48.0, 17.0 ],
+					"presentation_rect" : [ 278.0, 252.0, 48.0, 17.0 ],
 					"fontname" : "Verdana"
 				}
 
@@ -1616,7 +1682,7 @@
 					"numinlets" : 1,
 					"numoutlets" : 1,
 					"outlettype" : [ "bang" ],
-					"presentation_rect" : [ 19.0, 422.0, 20.0, 20.0 ]
+					"presentation_rect" : [ 284.0, 268.0, 33.0, 33.0 ]
 				}
 
 			}
@@ -1848,7 +1914,7 @@
 , 			{
 				"box" : 				{
 					"maxclass" : "message",
-					"text" : "55025.8125 0.",
+					"text" : "16575.537109 0.",
 					"patching_rect" : [ 1428.0, 920.0, 101.0, 17.0 ],
 					"id" : "obj-126",
 					"numinlets" : 2,
@@ -2074,7 +2140,7 @@
 , 			{
 				"box" : 				{
 					"maxclass" : "message",
-					"text" : "prefix Supersaurus:/Gronk/Gronkn/Bounces/MarbleArchMultitracks/Take3/",
+					"text" : "prefix Supersaurus:/Gronk/Gronkn/Bounces/StationGateMultitracks/TakeOneHalf/",
 					"linecount" : 3,
 					"patching_rect" : [ 1296.0, -79.0, 325.0, 41.0 ],
 					"id" : "obj-23",
@@ -2233,7 +2299,7 @@
 , 			{
 				"box" : 				{
 					"maxclass" : "textedit",
-					"text" : "Supersaurus:/Gronk/Gronkn/Bounces/MarbleArchMultitracks/Take3/",
+					"text" : "Supersaurus:/Gronk/Gronkn/Bounces/StationGateMultitracks/TakeOneHalf/",
 					"linecount" : 2,
 					"presentation_linecount" : 2,
 					"patching_rect" : [ 1014.0, -162.0, 270.0, 19.0 ],
@@ -2274,11 +2340,11 @@
 					"autopopulate" : 1,
 					"numinlets" : 1,
 					"fontsize" : 11.595187,
-					"prefix" : "Supersaurus:/Gronk/Gronkn/Bounces/MarbleArchMultitracks/Take3/",
+					"prefix" : "Supersaurus:/Gronk/Gronkn/Bounces/StationGateMultitracks/TakeOneHalf/",
 					"numoutlets" : 3,
 					"outlettype" : [ "int", "", "" ],
 					"presentation_rect" : [ 523.0, 77.0, 243.0, 20.0 ],
-					"items" : [ "01Bass.wav", ",", "02Kick_bip.wav", ",", "03Snare_bip.wav", ",", "04Elec_SM57_bip.wav", ",", "Ac D.I.wav", ",", "Ac Ribbon_bip.wav", ",", "AKG_L_bip.wav", ",", "AKG_R_bip.wav", ",", "Claud D.I.wav", ",", "Guide Vocal_bip.wav" ],
+					"items" : [ "Ac D.I.wav", ",", "Ac Ribbon_bip.wav", ",", "AKG_L_bip.wav", ",", "AKG_R_bip.wav", ",", "Bass D.I.wav", ",", "Elec SM57_bip.wav", ",", "Guide Vocal_bip.wav", ",", "Kick_bip.wav", ",", "Room Neu_bip.wav", ",", "Snare Bottom_bip.wav", ",", "Snare_bip.wav" ],
 					"fontname" : "Arial"
 				}
 
@@ -3558,7 +3624,7 @@
 , 			{
 				"box" : 				{
 					"maxclass" : "message",
-					"text" : "/snare 2 52924",
+					"text" : "/snare 2 11363",
 					"patching_rect" : [ 988.0, 758.0, 130.0, 17.0 ],
 					"id" : "obj-53",
 					"numinlets" : 2,
@@ -3656,7 +3722,7 @@
 , 			{
 				"box" : 				{
 					"maxclass" : "message",
-					"text" : "/aubioPitch 1 61.745316 51322",
+					"text" : "/aubioPitch 1 46.428551 11211",
 					"linecount" : 2,
 					"presentation_linecount" : 2,
 					"patching_rect" : [ 484.0, 767.0, 120.0, 29.0 ],
@@ -3666,7 +3732,7 @@
 					"fontsize" : 10.0,
 					"numoutlets" : 1,
 					"outlettype" : [ "" ],
-					"presentation_rect" : [ 333.0, 414.0, 120.0, 29.0 ],
+					"presentation_rect" : [ 13.0, 480.0, 120.0, 29.0 ],
 					"fontname" : "Verdana"
 				}
 
@@ -4316,7 +4382,7 @@
 					"fontsize" : 10.0,
 					"numoutlets" : 2,
 					"outlettype" : [ "float", "bang" ],
-					"presentation_rect" : [ 335.0, 392.0, 50.0, 19.0 ],
+					"presentation_rect" : [ 15.0, 458.0, 50.0, 19.0 ],
 					"fontname" : "Verdana"
 				}
 
@@ -5388,7 +5454,6 @@
 						"enablehscroll" : 1,
 						"enablevscroll" : 1,
 						"devicewidth" : 0.0,
-						"visible" : 1,
 						"boxes" : [ 							{
 								"box" : 								{
 									"maxclass" : "newobj",
@@ -5603,7 +5668,7 @@
 , 							{
 								"box" : 								{
 									"maxclass" : "message",
-									"text" : "61.745316 51322",
+									"text" : "46.428551 11211",
 									"patching_rect" : [ 50.0, 305.0, 187.0, 17.0 ],
 									"id" : "obj-65",
 									"numinlets" : 2,
@@ -6869,7 +6934,7 @@
 , 			{
 				"box" : 				{
 					"maxclass" : "message",
-					"text" : "/kick 0 52657",
+					"text" : "/kick 0 6286",
 					"patching_rect" : [ 692.0, 755.0, 130.0, 17.0 ],
 					"id" : "obj-112",
 					"numinlets" : 2,
@@ -6983,7 +7048,7 @@
 					"fontsize" : 10.0,
 					"numoutlets" : 3,
 					"outlettype" : [ "int", "", "" ],
-					"presentation_rect" : [ 391.0, 249.0, 100.0, 19.0 ],
+					"presentation_rect" : [ 5.0, 355.0, 81.0, 19.0 ],
 					"items" : [ "click", "off", ",", "slope", "detect", ",", "threshold", "detect" ],
 					"fontname" : "Verdana"
 				}
@@ -7249,6 +7314,51 @@
  ],
 		"lines" : [ 			{
 				"patchline" : 				{
+					"source" : [ "obj-206", 0 ],
+					"destination" : [ "obj-172", 0 ],
+					"hidden" : 0,
+					"midpoints" : [  ]
+				}
+
+			}
+, 			{
+				"patchline" : 				{
+					"source" : [ "obj-205", 0 ],
+					"destination" : [ "obj-52", 0 ],
+					"hidden" : 0,
+					"midpoints" : [  ]
+				}
+
+			}
+, 			{
+				"patchline" : 				{
+					"source" : [ "obj-204", 0 ],
+					"destination" : [ "obj-146", 0 ],
+					"hidden" : 0,
+					"midpoints" : [  ]
+				}
+
+			}
+, 			{
+				"patchline" : 				{
+					"source" : [ "obj-203", 0 ],
+					"destination" : [ "obj-8", 0 ],
+					"hidden" : 0,
+					"midpoints" : [  ]
+				}
+
+			}
+, 			{
+				"patchline" : 				{
+					"source" : [ "obj-43", 0 ],
+					"destination" : [ "obj-202", 0 ],
+					"hidden" : 0,
+					"midpoints" : [  ]
+				}
+
+			}
+, 			{
+				"patchline" : 				{
 					"source" : [ "obj-92", 0 ],
 					"destination" : [ "obj-66", 0 ],
 					"hidden" : 0,
@@ -7798,15 +7908,6 @@
 			}
 , 			{
 				"patchline" : 				{
-					"source" : [ "obj-43", 0 ],
-					"destination" : [ "obj-8", 0 ],
-					"hidden" : 0,
-					"midpoints" : [  ]
-				}
-
-			}
-, 			{
-				"patchline" : 				{
 					"source" : [ "obj-10", 0 ],
 					"destination" : [ "obj-8", 0 ],
 					"hidden" : 0,
@@ -8357,24 +8458,6 @@
 , 			{
 				"patchline" : 				{
 					"source" : [ "obj-43", 0 ],
-					"destination" : [ "obj-146", 0 ],
-					"hidden" : 0,
-					"midpoints" : [  ]
-				}
-
-			}
-, 			{
-				"patchline" : 				{
-					"source" : [ "obj-43", 0 ],
-					"destination" : [ "obj-52", 0 ],
-					"hidden" : 0,
-					"midpoints" : [  ]
-				}
-
-			}
-, 			{
-				"patchline" : 				{
-					"source" : [ "obj-43", 0 ],
 					"destination" : [ "obj-91", 0 ],
 					"hidden" : 0,
 					"midpoints" : [  ]
--- a/src/AudioEventMatcher.cpp	Mon Apr 02 18:47:25 2012 +0100
+++ b/src/AudioEventMatcher.cpp	Tue Apr 03 13:13:38 2012 +0100
@@ -407,8 +407,11 @@
 void AudioEventMatcher::newChromaEvent(const int& channel, float* chromaIn, const double& timeIn){
 	
 	//	could add event to the liveInput list? as in pitch event
-//	printf("match chroma channel %i\n", channel);	
-
+	printf("match chroma channel %i\n", channel);	
+	for (int i = 0;i < 12;i++){
+		printf("chroma in[%i] = %f\n", i, chromaIn[i]);
+	}
+	
 	matchNewChromaEvent(channel, chromaIn, timeIn);//main pitch matching fn
 	
 	likelihoodVisualisation[channel] = bayesianStruct.likelihood;
--- a/src/RecordedMultitrackAudio.cpp	Mon Apr 02 18:47:25 2012 +0100
+++ b/src/RecordedMultitrackAudio.cpp	Tue Apr 03 13:13:38 2012 +0100
@@ -16,7 +16,7 @@
 
 	printf("loaded max val  is %f\n", loadedAudioFiles[0].fileLoader.onsetDetect.onsetDetector.maximumDetectionValue);
 	
-	setDifferentMultitracks(13);//command to load this set of audio files - see below
+	setDifferentMultitracks(15);//command to load this set of audio files - see below
 	
 	//number 7 is problematic with memory
 	
@@ -121,7 +121,21 @@
 			snarefilename ="/Volumes/Supersaurus/Gronk/Gronkn/Bounces/MarbleArchMultitracks/Take6/03Snare_bip.wav";	
 			guitarfilename ="/Volumes/Supersaurus/Gronk/Gronkn/Bounces/MarbleArchMultitracks/Take6/04Elec_SM57_bip.wav";	
 			break;		
-						
+			
+			
+		case 14:
+			kickfilename = "/Volumes/Supersaurus/Gronk/Gronkn/Bounces/StationGateMultitracks/TakeOneFull/02Kick_bip.wav";
+			bassfilename = "/Volumes/Supersaurus/Gronk/Gronkn/Bounces/StationGateMultitracks/TakeOneFull/01Bass.wav";
+			snarefilename ="/Volumes/Supersaurus/Gronk/Gronkn/Bounces/StationGateMultitracks/TakeOneFull/03Snare_bip.wav";	
+			guitarfilename ="/Volumes/Supersaurus/Gronk/Gronkn/Bounces/StationGateMultitracks/TakeOneFull/04Elec_SM57_bip.wav";	
+			break;			
+	
+		case 15:
+			kickfilename = "/Volumes/Supersaurus/Gronk/Gronkn/Bounces/StationGateMultitracks/TakeTwoFull/02Kick_bip.wav";
+			bassfilename = "/Volumes/Supersaurus/Gronk/Gronkn/Bounces/StationGateMultitracks/TakeTwoFull/01Bass.wav";
+			snarefilename ="/Volumes/Supersaurus/Gronk/Gronkn/Bounces/StationGateMultitracks/TakeTwoFull/03Snare_bip.wav";	
+			guitarfilename ="/Volumes/Supersaurus/Gronk/Gronkn/Bounces/StationGateMultitracks/TakeTwoFull/04Elec_SM57_bip.wav";	
+			break;							
 			
 	}
 	loadAudioTrack(kickfilename, 0);