changeset 26:b3a5950ebb3f

Parameter descriptor, plugin static data
author Chris Cannam
date Tue, 08 Mar 2016 17:02:35 +0000
parents 1bf1ea70e386
children 4a33a6bfc4b8
files examples/feat.json examples/outputdesc.json examples/paramdesc.json examples/staticdata.json schema/parameterdescriptor.json schema/pluginstaticdata.json
diffstat 6 files changed, 89 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/feat.json	Tue Mar 08 17:02:35 2016 +0000
@@ -0,0 +1,1 @@
+[[{"b64values": "AACAPwAAAEAEAEBAAACAQAAAoEAAAMBAAADQQAAA4EA", "label": "A feature", "timestamp": {"n": 141590000, "s": 3}}]]
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/outputdesc.json	Tue Mar 08 17:02:35 2016 +0000
@@ -0,0 +1,2 @@
+{"basic": {"description": "Power values of the frequency spectrum bins calculated from the input signal", "identifier": "powerspectrum", "name": "Power Spectrum"}, "binCount": 513, "binNames": [], "hasDuration": false, "sampleRate": 0, "sampleType": "OneSamplePerStep", "unit": ""}
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/paramdesc.json	Tue Mar 08 17:02:35 2016 +0000
@@ -0,0 +1,2 @@
+{"basic": {"description": "Energy rise within a frequency bin necessary to count toward broadband total", "identifier": "threshold", "name": "Energy rise threshold"}, "defaultValue": 3, "maxValue": 20.5, "minValue": 0, "unit": "dB", "valueNames": []}
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/staticdata.json	Tue Mar 08 17:02:35 2016 +0000
@@ -0,0 +1,1 @@
+{"basic": {"description": "Detect percussive note onsets by identifying broadband energy rises", "identifier": "percussiononsets", "name": "Simple Percussion Onset Detector"}, "basicOutputInfo": [{"description": "Percussive note onset locations", "identifier": "onsets", "name": "Onsets"}, {"description": "Broadband energy rise detection function", "identifier": "detectionfunction", "name": "Detection Function"}], "category": ["Time", "Onsets"], "copyright": "Code copyright 2006 Queen Mary, University of London, after Dan Barry et al 2005.  Freely redistributable (BSD license)", "inputDomain": "FrequencyDomain", "key": "vamp-example-plugins:percussiononsets", "maker": "Vamp SDK Example Plugins", "maxChannelCount": 1, "minChannelCount": 1, "parameters": [{"basic": {"description": "Energy rise within a frequency bin necessary to count toward broadband total", "identifier": "threshold", "name": "Energy rise threshold"}, "defaultValue": 3, "maxValue": 20, "minValue": 0, "unit": "dB", "valueNames": []}, {"basic": {"description": "Sensitivity of peak detector applied to broadband detection function", "identifier": "sensitivity", "name": "Sensitivity"}, "defaultValue": 40, "maxValue": 100, "minValue": 0, "unit": "%", "valueNames": []}], "programs": [], "version": 2}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/schema/parameterdescriptor.json	Tue Mar 08 17:02:35 2016 +0000
@@ -0,0 +1,30 @@
+{
+    "id": "http://vamp-plugins.org/json/schema/parameterdescriptor#",
+    "$schema": "http://json-schema.org/draft-04/schema#",
+    "description": "schema for a Vamp::PluginBase::ParameterDescriptor serialisation",
+    "type": "object",
+    "properties": {
+	"basic": {
+	    "$ref": "http://vamp-plugins.org/json/schema/basic#"
+	},
+	"unit": {
+	    "type": "string"
+	},
+	"extents": {
+	    "$ref": "http://vamp-plugins.org/json/schema/valueextents#"
+	},
+	"defaultValue": {
+	    "type": "number"
+	},
+	"quantizeStep": {
+	    "type": "number"
+	},
+	"valueNames": {
+	    "type": "array",
+	    "items": { "type": "string" }
+	}
+    },
+    "required": [ "basic", "extents", "defaultValue" ],
+    "additionalProperties": false
+}
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/schema/pluginstaticdata.json	Tue Mar 08 17:02:35 2016 +0000
@@ -0,0 +1,53 @@
+{
+    "id": "http://vamp-plugins.org/json/schema/pluginstaticdata#",
+    "$schema": "http://json-schema.org/draft-04/schema#",
+    "description": "schema for a serialised bundle of the static data associated with a Vamp Plugin",
+    "type": "object",
+    "properties": {
+	"key": {
+	    "type": "string"
+	},
+	"basic": {
+	    "$ref": "http://vamp-plugins.org/json/schema/basic#"
+	},
+	"maker": {
+	    "type": "string"
+	},
+	"copyright": {
+	    "type": "string"
+	},
+	"version": {
+	    "type": "integer"
+	},
+	"category": {
+	    "type": "array",
+	    "items": { "type": "string" }
+	},
+	"minChannelCount": {
+	    "type": "integer"
+	},
+	"maxChannelCount": {
+	    "type": "integer"
+	},
+	"parameters": {
+	    "type": "array",
+	    "items": { "$ref": "http://vamp-plugins.org/json/schema/parameterdescriptor#" }
+	},
+	"programs": {
+	    "type": "array",
+	    "items": { "type": "string" }
+	},
+	"inputDomain": {
+	    "$ref": "http://vamp-plugins.org/json/schema/enums#/definitions/input_domain"
+	},
+	"basicOutputInfo": {
+	    "type": "array",
+	    "items": { "$ref": "http://vamp-plugins.org/json/schema/basic#" }
+	}
+    },
+    "required": [ "key", "basic", "version",
+		  "minChannelCount", "maxChannelCount",
+		  "inputDomain", "basicOutputInfo" ],
+    "additionalProperties": false
+}
+