changeset 273:5db279f1e0f8 piper-nopiper

Switch the multiple-audio tests to using amplitudefollower -- percussiononsets is too sensitive to the very low-level noise that comes from variations in mp3 decoder fixed-point arithmetic function choice
author Chris Cannam
date Fri, 25 Nov 2016 13:37:02 +0000
parents 45892d8efa4c
children bfad84d0bb1d
files tests/test-multiple-audio/expected/all-files.csv tests/test-multiple-audio/expected/multiplexed.csv tests/test-multiple-audio/expected/playlist.csv tests/test-multiple-audio/test-multiple-audio.sh tests/test-multiple-audio/transforms/af.n3
diffstat 5 files changed, 90 insertions(+), 49 deletions(-) [+]
line wrap: on
line diff
--- a/tests/test-multiple-audio/expected/all-files.csv	Fri Nov 25 11:41:53 2016 +0000
+++ b/tests/test-multiple-audio/expected/all-files.csv	Fri Nov 25 13:37:02 2016 +0000
@@ -1,36 +1,36 @@
-"./../audio/20sec-silence.wav",0.000000000,20.015600907,mean,61.1636,"(mean value, continuous-time average)"
-,0.000000000,20.015600907,median,0,"(median value, continuous-time average)"
-,0.000000000,20.015600907,mode,0,"(modal value, continuous-time average)"
-,0.000000000,20.015600907,mean,1406.56,"(mean value, continuous-time average)"
-"./../audio/3clicks.mp3",0.000000000,5.061950114,mean,174.507,"(mean value, continuous-time average)"
-,0.000000000,5.061950114,median,173,"(median value, continuous-time average)"
-,0.000000000,5.061950114,mode,173,"(modal value, continuous-time average)"
-,0.000000000,5.061950114,mean,1510.95,"(mean value, continuous-time average)"
-"./../audio/3clicks.ogg",0.000000000,4.992290250,mean,169.481,"(mean value, continuous-time average)"
-,0.000000000,4.992290250,median,156,"(median value, continuous-time average)"
-,0.000000000,4.992290250,mode,132,"(modal value, continuous-time average)"
-,0.000000000,4.992290250,mean,1480.59,"(mean value, continuous-time average)"
-"./../audio/3clicks8.wav",0.000000000,4.992290250,mean,169.391,"(mean value, continuous-time average)"
-,0.000000000,4.992290250,median,169,"(median value, continuous-time average)"
-,0.000000000,4.992290250,mode,164,"(modal value, continuous-time average)"
-,0.000000000,4.992290250,mean,1403.77,"(mean value, continuous-time average)"
-"./../audio/3clicks8quiet.wav",0.000000000,4.992290250,mean,169.058,"(mean value, continuous-time average)"
-,0.000000000,4.992290250,median,169,"(median value, continuous-time average)"
-,0.000000000,4.992290250,mode,165,"(modal value, continuous-time average)"
-,0.000000000,4.992290250,mean,1342.8,"(mean value, continuous-time average)"
-"./../audio/6clicks.ogg",0.000000000,9.961360545,mean,168.686,"(mean value, continuous-time average)"
-,0.000000000,9.961360545,median,158,"(median value, continuous-time average)"
-,0.000000000,9.961360545,mode,138,"(modal value, continuous-time average)"
-,0.000000000,9.961360545,mean,1423.64,"(mean value, continuous-time average)"
-"./../audio/6clicks8.wav",0.000000000,9.961360545,mean,170.174,"(mean value, continuous-time average)"
-,0.000000000,9.961360545,median,169,"(median value, continuous-time average)"
-,0.000000000,9.961360545,mode,164,"(modal value, continuous-time average)"
-,0.000000000,9.961360545,mean,1411.85,"(mean value, continuous-time average)"
-"./../audio/id3v2-iso-8859-1.mp3",0.000000000,5.015510204,mean,176.083,"(mean value, continuous-time average)"
-,0.000000000,5.015510204,median,172,"(median value, continuous-time average)"
-,0.000000000,5.015510204,mode,164,"(modal value, continuous-time average)"
-,0.000000000,5.015510204,mean,1492.7,"(mean value, continuous-time average)"
-"./../audio/id3v2-ucs-2.mp3",0.000000000,5.061950114,mean,174.507,"(mean value, continuous-time average)"
-,0.000000000,5.061950114,median,173,"(median value, continuous-time average)"
-,0.000000000,5.061950114,mode,173,"(modal value, continuous-time average)"
-,0.000000000,5.061950114,mean,1510.95,"(mean value, continuous-time average)"
+"./../audio/20sec-silence.wav",0.000000000,20.015600907,mean,2.89986e-5,"(mean value, continuous-time average)"
+,0.000000000,20.015600907,median,3.05174e-5,"(median value, continuous-time average)"
+,0.000000000,20.015600907,mode,3.05174e-5,"(modal value, continuous-time average)"
+,0.000000000,20.015600907,mean,3.96499e-5,"(mean value, continuous-time average)"
+"./../audio/3clicks.mp3",0.000000000,5.061950114,mean,0.000274699,"(mean value, continuous-time average)"
+,0.000000000,5.061950114,median,1.64523e-5,"(median value, continuous-time average)"
+,0.000000000,5.061950114,mode,1.66701e-5,"(modal value, continuous-time average)"
+,0.000000000,5.061950114,mean,0.000840842,"(mean value, continuous-time average)"
+"./../audio/3clicks.ogg",0.000000000,4.992290250,mean,0.00030312,"(mean value, continuous-time average)"
+,0.000000000,4.992290250,median,2.42053e-5,"(median value, continuous-time average)"
+,0.000000000,4.992290250,mode,1.98849e-5,"(modal value, continuous-time average)"
+,0.000000000,4.992290250,mean,0.00108189,"(mean value, continuous-time average)"
+"./../audio/3clicks8.wav",0.000000000,4.992290250,mean,0.00369413,"(mean value, continuous-time average)"
+,0.000000000,4.992290250,median,0.00353596,"(median value, continuous-time average)"
+,0.000000000,4.992290250,mode,0.00333629,"(modal value, continuous-time average)"
+,0.000000000,4.992290250,mean,0.00419638,"(mean value, continuous-time average)"
+"./../audio/3clicks8quiet.wav",0.000000000,4.992290250,mean,0.00548326,"(mean value, continuous-time average)"
+,0.000000000,4.992290250,median,0.00548263,"(median value, continuous-time average)"
+,0.000000000,4.992290250,mode,0.00515389,"(modal value, continuous-time average)"
+,0.000000000,4.992290250,mean,0.00563474,"(mean value, continuous-time average)"
+"./../audio/6clicks.ogg",0.000000000,9.961360545,mean,0.00396273,"(mean value, continuous-time average)"
+,0.000000000,9.961360545,median,0.00372425,"(median value, continuous-time average)"
+,0.000000000,9.961360545,mode,0.00358366,"(modal value, continuous-time average)"
+,0.000000000,9.961360545,mean,0.00468354,"(mean value, continuous-time average)"
+"./../audio/6clicks8.wav",0.000000000,9.961360545,mean,0.00368836,"(mean value, continuous-time average)"
+,0.000000000,9.961360545,median,0.00353795,"(median value, continuous-time average)"
+,0.000000000,9.961360545,mode,0.00345758,"(modal value, continuous-time average)"
+,0.000000000,9.961360545,mean,0.00417255,"(mean value, continuous-time average)"
+"./../audio/id3v2-iso-8859-1.mp3",0.000000000,5.061950114,mean,0.000274699,"(mean value, continuous-time average)"
+,0.000000000,5.061950114,median,1.64523e-5,"(median value, continuous-time average)"
+,0.000000000,5.061950114,mode,1.66701e-5,"(modal value, continuous-time average)"
+,0.000000000,5.061950114,mean,0.000840842,"(mean value, continuous-time average)"
+"./../audio/id3v2-ucs-2.mp3",0.000000000,5.061950114,mean,0.000274699,"(mean value, continuous-time average)"
+,0.000000000,5.061950114,median,1.64523e-5,"(median value, continuous-time average)"
+,0.000000000,5.061950114,mode,1.66701e-5,"(modal value, continuous-time average)"
+,0.000000000,5.061950114,mean,0.000840842,"(mean value, continuous-time average)"
--- a/tests/test-multiple-audio/expected/multiplexed.csv	Fri Nov 25 11:41:53 2016 +0000
+++ b/tests/test-multiple-audio/expected/multiplexed.csv	Fri Nov 25 13:37:02 2016 +0000
@@ -1,4 +1,4 @@
-"3clicks.mp3",0.000000000,9.961360545,mean,168.908,"(mean value, continuous-time average)"
-,0.000000000,9.961360545,median,162,"(median value, continuous-time average)"
-,0.000000000,9.961360545,mode,144,"(modal value, continuous-time average)"
-,0.000000000,9.961360545,mean,1418.17,"(mean value, continuous-time average)"
+"3clicks.mp3",0.000000000,9.961360545,mean,0.00202899,"(mean value, continuous-time average)"
+,0.000000000,9.961360545,median,0.00186213,"(median value, continuous-time average)"
+,0.000000000,9.961360545,mode,0.00179183,"(modal value, continuous-time average)"
+,0.000000000,9.961360545,mean,0.00240067,"(mean value, continuous-time average)"
--- a/tests/test-multiple-audio/expected/playlist.csv	Fri Nov 25 11:41:53 2016 +0000
+++ b/tests/test-multiple-audio/expected/playlist.csv	Fri Nov 25 13:37:02 2016 +0000
@@ -1,8 +1,8 @@
-"3clicks.mp3",0.000000000,5.061950114,mean,174.507,"(mean value, continuous-time average)"
-,0.000000000,5.061950114,median,173,"(median value, continuous-time average)"
-,0.000000000,5.061950114,mode,173,"(modal value, continuous-time average)"
-,0.000000000,5.061950114,mean,1510.95,"(mean value, continuous-time average)"
-"6clicks.ogg",0.000000000,9.961360545,mean,168.686,"(mean value, continuous-time average)"
-,0.000000000,9.961360545,median,158,"(median value, continuous-time average)"
-,0.000000000,9.961360545,mode,138,"(modal value, continuous-time average)"
-,0.000000000,9.961360545,mean,1423.64,"(mean value, continuous-time average)"
+"3clicks.mp3",0.000000000,5.061950114,mean,0.000274699,"(mean value, continuous-time average)"
+,0.000000000,5.061950114,median,1.64523e-5,"(median value, continuous-time average)"
+,0.000000000,5.061950114,mode,1.66701e-5,"(modal value, continuous-time average)"
+,0.000000000,5.061950114,mean,0.000840842,"(mean value, continuous-time average)"
+"6clicks.ogg",0.000000000,9.961360545,mean,0.00396273,"(mean value, continuous-time average)"
+,0.000000000,9.961360545,median,0.00372425,"(median value, continuous-time average)"
+,0.000000000,9.961360545,mode,0.00358366,"(modal value, continuous-time average)"
+,0.000000000,9.961360545,mean,0.00468354,"(mean value, continuous-time average)"
--- a/tests/test-multiple-audio/test-multiple-audio.sh	Fri Nov 25 11:41:53 2016 +0000
+++ b/tests/test-multiple-audio/test-multiple-audio.sh	Fri Nov 25 13:37:02 2016 +0000
@@ -7,7 +7,7 @@
 
 trap "rm -f $tmpfile1 $tmpfile2" 0
 
-transform=$mypath/transforms/detectionfunction.n3 
+transform=$mypath/transforms/af.n3 
 
 urlbase=http://vamp-plugins.org/sonic-annotator/testfiles
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-multiple-audio/transforms/af.n3	Fri Nov 25 13:37:02 2016 +0000
@@ -0,0 +1,41 @@
+@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>.
+@prefix vamp: <http://purl.org/ontology/vamp/>.
+@prefix examples: <http://vamp-plugins.org/rdf/plugins/vamp-example-plugins#>.
+@prefix : <#>.
+
+:transform0 a vamp:Transform;
+	vamp:plugin examples:amplitudefollower ;
+	vamp:output examples:amplitudefollower_output_amplitude ;
+	vamp:summary_type "mean" .
+
+:transform1 a vamp:Transform;
+	vamp:plugin examples:amplitudefollower ;
+	vamp:output examples:amplitudefollower_output_amplitude ;
+	vamp:summary_type "median" .
+
+# This is not a summary and so should not appear with --summary-only
+:transform2 a vamp:Transform;
+	vamp:plugin examples:percussiononsets ;
+	vamp:output examples:percussiononsets_output_onsets .
+
+:transform3 a vamp:Transform;
+	vamp:plugin examples:amplitudefollower ;
+	vamp:output examples:amplitudefollower_output_amplitude ;
+	vamp:summary_type "mode" .
+
+# This has different step and block sizes from the default
+# (:transform0), and so should be listed separately with different
+# values in the output
+:transform4 a vamp:Transform;
+	vamp:plugin examples:amplitudefollower ;
+	vamp:output examples:amplitudefollower_output_amplitude ;
+	vamp:step_size 4096 ;
+	vamp:block_size 8192 ;
+	vamp:summary_type "mean" .
+
+# This is not a summary and so should not appear with --summary-only
+:transform5 a vamp:Transform;
+	vamp:plugin examples:amplitudefollower ;
+	vamp:output examples:amplitudefollower_output_amplitude .
+
+