# HG changeset patch # User Chris Cannam # Date 1416228831 0 # Node ID f5b8646494d2d8089badcdbaf31c5ea779ca7428 # Parent 44d56a3d16b728fbfeccd591068aca37ac96a4c5 Metadata fixes diff -r 44d56a3d16b7 -r f5b8646494d2 Example VamPy plugins/PyMFCC.py --- a/Example VamPy plugins/PyMFCC.py Mon Nov 17 11:44:15 2014 +0000 +++ b/Example VamPy plugins/PyMFCC.py Mon Nov 17 12:53:51 2014 +0000 @@ -153,7 +153,7 @@ return 'Vampy Example Plugins' def getCopyright(self): - return 'Plugin By George Fazekas' + return 'Plugin By George Fazekas. Freely redistributable example plugin (BSD license)' def getName(self): return 'Vampy MFCC Plugin' diff -r 44d56a3d16b7 -r f5b8646494d2 Example VamPy plugins/PySpectralCentroid.py --- a/Example VamPy plugins/PySpectralCentroid.py Mon Nov 17 11:44:15 2014 +0000 +++ b/Example VamPy plugins/PySpectralCentroid.py Mon Nov 17 12:53:51 2014 +0000 @@ -4,7 +4,7 @@ extension module. The plugin has frequency domain input and is using the -legacy interface: the FFT outpout is passed as a list +legacy interface: the FFT output is passed as a list of complex numbers. Outputs: @@ -57,7 +57,13 @@ def getIdentifier(self): return 'vampy-sc3' - + + def getDescription(self): + return 'Calculate the linear frequency centroid of the short-time Fourier spectrum' + + def getCopyright(self): + return 'Plugin By George Fazekas. Freely redistributable example plugin (BSD license)' + def getMaxChannelCount(self): return 1 diff -r 44d56a3d16b7 -r f5b8646494d2 Example VamPy plugins/PySpectralFeatures.py --- a/Example VamPy plugins/PySpectralFeatures.py Mon Nov 17 11:44:15 2014 +0000 +++ b/Example VamPy plugins/PySpectralFeatures.py Mon Nov 17 12:53:51 2014 +0000 @@ -54,7 +54,10 @@ def getDescription(self): return 'A collection of low-level spectral descriptors.' - + + def getCopyright(self): + return 'Plugin By George Fazekas. Freely redistributable example plugin (BSD license)' + def getMaxChannelCount(self): return 1 diff -r 44d56a3d16b7 -r f5b8646494d2 Example VamPy plugins/PyZeroCrossing.py --- a/Example VamPy plugins/PyZeroCrossing.py Mon Nov 17 11:44:15 2014 +0000 +++ b/Example VamPy plugins/PyZeroCrossing.py Mon Nov 17 12:53:51 2014 +0000 @@ -39,6 +39,12 @@ def getName(self): return 'Vampy Zero Crossings' + + def getDescription(self): + return 'Count the number of simple zero-crossings for the signal within each processing block' + + def getCopyright(self): + return 'Plugin By George Fazekas. Freely redistributable example plugin (BSD license)' def getIdentifier(self): return 'vampy-zc2' diff -r 44d56a3d16b7 -r f5b8646494d2 Example VamPy plugins/examples.n3 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Example VamPy plugins/examples.n3 Mon Nov 17 12:53:51 2014 +0000 @@ -0,0 +1,337 @@ +@prefix rdfs: . +@prefix xsd: . +@prefix vamp: . +@prefix plugbase: . +@prefix owl: . +@prefix dc: . +@prefix af: . +@prefix foaf: . +@prefix doap: . +@prefix cc: . +@prefix : <#> . + + +## Properties of this document + +<> a vamp:PluginDescription ; + foaf:maker ; + foaf:primaryTopic . + + +## Maker of the whole plugin library + +:library_maker + foaf:name "Vampy Example Plugins" ; +# foaf:page <> ; # Place maker's homepage URL in here and uncomment +# foaf:logo <> ; # URL of an image here, if you happen to have a logo + . + + +## Properties of the plugin library, and references to the plugins it contains + +plugbase:library a vamp:PluginLibrary ; + vamp:identifier "vampy" ; + foaf:maker :library_maker ; + vamp:available_plugin plugbase:vampy-mfcc ; + vamp:available_plugin plugbase:vampy-sc3 ; + vamp:available_plugin plugbase:vampy-sf3 ; + vamp:available_plugin plugbase:vampy-zc2 ; +# dc:title "" ; # Place library name here and uncomment +# dc:description "" ; # Place library description here and uncomment +# foaf:page <> ; # Place more-info HTML page URL here and uncomment +# doap:download-page <> ; # Place download HTML page URL here and uncomment + . + + +## Properties of the Vampy MFCC Plugin plugin + +plugbase:vampy-mfcc a vamp:Plugin ; + dc:title "Vampy MFCC Plugin" ; + vamp:name "Vampy MFCC Plugin" ; + dc:description """A simple MFCC plugin""" ; + foaf:maker :library_maker ; + dc:rights """Plugin By George Fazekas. Freely redistributable example plugin (BSD license)""" ; +# cc:license ; + vamp:identifier "vampy-mfcc" ; + vamp:vamp_API_version vamp:api_version_2 ; + owl:versionInfo "2" ; + vamp:input_domain vamp:FrequencyDomain ; + + vamp:parameter plugbase:vampy-mfcc_param_melbands ; + vamp:parameter plugbase:vampy-mfcc_param_minHz ; + vamp:parameter plugbase:vampy-mfcc_param_maxHz ; + vamp:parameter plugbase:vampy-mfcc_param_cnull ; + vamp:parameter plugbase:vampy-mfcc_param_two_ch ; + + vamp:output plugbase:vampy-mfcc_output_mfccs ; + vamp:output plugbase:vampy-mfcc_output_warped-fft ; + vamp:output plugbase:vampy-mfcc_output_mel-filter-matrix ; + . +plugbase:vampy-mfcc_param_melbands a vamp:QuantizedParameter ; + vamp:identifier "melbands" ; + dc:title "Number of bands (coefficients)" ; + dc:format "" ; + vamp:min_value 2 ; + vamp:max_value 128 ; + vamp:unit "" ; + vamp:quantize_step 1 ; + vamp:default_value 40 ; + vamp:value_names (); + . +plugbase:vampy-mfcc_param_minHz a vamp:QuantizedParameter ; + vamp:identifier "minHz" ; + dc:title "minimum frequency" ; + dc:format "Hz" ; + vamp:min_value 0 ; + vamp:max_value 24000 ; + vamp:unit "Hz" ; + vamp:quantize_step 1 ; + vamp:default_value 0 ; + vamp:value_names (); + . +plugbase:vampy-mfcc_param_maxHz a vamp:QuantizedParameter ; + vamp:identifier "maxHz" ; + dc:title "maximum frequency" ; + dc:format "Hz" ; + vamp:min_value 100 ; + vamp:max_value 24000 ; + vamp:unit "Hz" ; + vamp:quantize_step 100 ; + vamp:default_value 11025 ; + vamp:value_names (); + . +plugbase:vampy-mfcc_param_cnull a vamp:QuantizedParameter ; + vamp:identifier "cnull" ; + dc:title "Return C0" ; + dc:format "" ; + vamp:min_value 0 ; + vamp:max_value 1 ; + vamp:unit "" ; + vamp:quantize_step 1 ; + vamp:default_value 0 ; + vamp:value_names (); + . +plugbase:vampy-mfcc_param_two_ch a vamp:QuantizedParameter ; + vamp:identifier "two_ch" ; + dc:title "Process channels separately" ; + dc:format "" ; + vamp:min_value 0 ; + vamp:max_value 1 ; + vamp:unit "" ; + vamp:quantize_step 1 ; + vamp:default_value 0 ; + vamp:value_names (); + . +plugbase:vampy-mfcc_output_mfccs a vamp:DenseOutput ; + vamp:identifier "mfccs" ; + dc:title "MFCCs" ; + dc:description """MFCC Coefficients""" ; + vamp:fixed_bin_count "true" ; + vamp:unit "" ; + a vamp:QuantizedOutput ; + vamp:quantize_step -2.14949e+08 ; + vamp:bin_count 39 ; + vamp:bin_names ( "C 1" "C 2" "C 3" "C 4" "C 5" "C 6" "C 7" "C 8" "C 9" "C 10" "C 11" "C 12" "C 13" "C 14" "C 15" "C 16" "C 17" "C 18" "C 19" "C 20" "C 21" "C 22" "C 23" "C 24" "C 25" "C 26" "C 27" "C 28" "C 29" "C 30" "C 31" "C 32" "C 33" "C 34" "C 35" "C 36" "C 37" "C 38" "C 39"); +# vamp:computes_event_type ; +# vamp:computes_feature ; +# vamp:computes_signal_type ; + . +plugbase:vampy-mfcc_output_warped-fft a vamp:DenseOutput ; + vamp:identifier "warped-fft" ; + dc:title "Mel Scaled Spectrum" ; + dc:description """Mel Scaled Magnitide Spectrum""" ; + vamp:fixed_bin_count "true" ; + vamp:unit "Mel" ; + a vamp:QuantizedOutput ; + vamp:quantize_step -2.14949e+08 ; + vamp:bin_count 40 ; +# vamp:computes_event_type ; +# vamp:computes_feature ; +# vamp:computes_signal_type ; + . +plugbase:vampy-mfcc_output_mel-filter-matrix a vamp:DenseOutput ; + vamp:identifier "mel-filter-matrix" ; + dc:title "Mel Filter Matrix" ; + dc:description """Returns the created filter matrix in getRemainingFeatures.""" ; + vamp:fixed_bin_count "true" ; + vamp:unit "" ; + a vamp:QuantizedOutput ; + vamp:quantize_step -2.14949e+08 ; + vamp:bin_count 39 ; +# vamp:computes_event_type ; +# vamp:computes_feature ; +# vamp:computes_signal_type ; + . + +## Properties of the Spectral Centroid (using legacy process interface) plugin + +plugbase:vampy-sc3 a vamp:Plugin ; + dc:title "Spectral Centroid (using legacy process interface)" ; + vamp:name "Spectral Centroid (using legacy process interface)" ; + dc:description """Calculate the linear frequency centroid of the short-time Fourier spectrum""" ; + foaf:maker :library_maker ; + dc:rights """Plugin By George Fazekas. Freely redistributable example plugin (BSD license)""" ; +# cc:license ; + vamp:identifier "vampy-sc3" ; + vamp:vamp_API_version vamp:api_version_2 ; + owl:versionInfo "2" ; + vamp:input_domain vamp:FrequencyDomain ; + + vamp:parameter plugbase:vampy-sc3_param_threshold ; + + vamp:output plugbase:vampy-sc3_output_vampy-sc3 ; + . +plugbase:vampy-sc3_param_threshold a vamp:Parameter ; + vamp:identifier "threshold" ; + dc:title "Noise threshold" ; + dc:format "v" ; + vamp:min_value 0 ; + vamp:max_value 0.5 ; + vamp:unit "v" ; + vamp:default_value 0.05 ; + vamp:value_names (); + . +plugbase:vampy-sc3_output_vampy-sc3 a vamp:DenseOutput ; + vamp:identifier "vampy-sc3" ; + dc:title "Spectral Centroid" ; + dc:description """Spectral Centroid (Brightness)""" ; + vamp:fixed_bin_count "true" ; + vamp:unit "" ; + a vamp:QuantizedOutput ; + vamp:quantize_step 1 ; + vamp:bin_count 1 ; +# vamp:computes_event_type ; +# vamp:computes_feature ; +# vamp:computes_signal_type ; + . + +## Properties of the Vampy Spectral Features plugin + +plugbase:vampy-sf3 a vamp:Plugin ; + dc:title "Vampy Spectral Features" ; + vamp:name "Vampy Spectral Features" ; + dc:description """A collection of low-level spectral descriptors.""" ; + foaf:maker :library_maker ; + dc:rights """Plugin By George Fazekas. Freely redistributable example plugin (BSD license)""" ; +# cc:license ; + vamp:identifier "vampy-sf3" ; + vamp:vamp_API_version vamp:api_version_2 ; + owl:versionInfo "2" ; + vamp:input_domain vamp:FrequencyDomain ; + + vamp:parameter plugbase:vampy-sf3_param_threshold ; + + vamp:output plugbase:vampy-sf3_output_vampy-sc ; + vamp:output plugbase:vampy-sf3_output_vampy-scf ; + vamp:output plugbase:vampy-sf3_output_vampy-bw ; + vamp:output plugbase:vampy-sf3_output_vampy-sd ; + . +plugbase:vampy-sf3_param_threshold a vamp:Parameter ; + vamp:identifier "threshold" ; + dc:title "Noise threshold" ; + dc:format "v" ; + vamp:min_value 0 ; + vamp:max_value 1 ; + vamp:unit "v" ; + vamp:default_value 0.05 ; + vamp:value_names (); + . +plugbase:vampy-sf3_output_vampy-sc a vamp:DenseOutput ; + vamp:identifier "vampy-sc" ; + dc:title "Spectral Centroid" ; + dc:description """Spectral Centroid (Brightness)""" ; + vamp:fixed_bin_count "true" ; + vamp:unit "Hz" ; + vamp:bin_count 1 ; +# vamp:computes_event_type ; +# vamp:computes_feature ; +# vamp:computes_signal_type ; + . +plugbase:vampy-sf3_output_vampy-scf a vamp:DenseOutput ; + vamp:identifier "vampy-scf" ; + dc:title "Spectral Crest Factor" ; + dc:description """Spectral Crest (Tonality)""" ; + vamp:fixed_bin_count "true" ; + vamp:unit "v" ; + vamp:bin_count 1 ; +# vamp:computes_event_type ; +# vamp:computes_feature ; +# vamp:computes_signal_type ; + . +plugbase:vampy-sf3_output_vampy-bw a vamp:DenseOutput ; + vamp:identifier "vampy-bw" ; + dc:title "Band Width" ; + dc:description """Spectral Band Width""" ; + vamp:fixed_bin_count "true" ; + vamp:unit "Hz" ; + vamp:bin_count 1 ; +# vamp:computes_event_type ; +# vamp:computes_feature ; +# vamp:computes_signal_type ; + . +plugbase:vampy-sf3_output_vampy-sd a vamp:DenseOutput ; + vamp:identifier "vampy-sd" ; + dc:title "Spectral Difference" ; + dc:description """Eucledian distance of successive magnitude spectra.""" ; + vamp:fixed_bin_count "true" ; + vamp:unit "Hz" ; + vamp:bin_count 1 ; +# vamp:computes_event_type ; +# vamp:computes_feature ; +# vamp:computes_signal_type ; + . + +## Properties of the Vampy Zero Crossings plugin + +plugbase:vampy-zc2 a vamp:Plugin ; + dc:title "Vampy Zero Crossings" ; + vamp:name "Vampy Zero Crossings" ; + dc:description """Count the number of simple zero-crossings for the signal within each processing block""" ; + foaf:maker :library_maker ; + dc:rights """Plugin By George Fazekas. Freely redistributable example plugin (BSD license)""" ; +# cc:license ; + vamp:identifier "vampy-zc2" ; + vamp:vamp_API_version vamp:api_version_2 ; + owl:versionInfo "2" ; + vamp:input_domain vamp:TimeDomain ; + vamp:parameter plugbase:vampy-zc2_param_threshold ; + + vamp:output plugbase:vampy-zc2_output_vampy-counts ; + vamp:output plugbase:vampy-zc2_output_vampy-crossings ; + . +plugbase:vampy-zc2_param_threshold a vamp:Parameter ; + vamp:identifier "threshold" ; + dc:title "Noise threshold" ; + dc:format "v" ; + vamp:min_value 0 ; + vamp:max_value 0.5 ; + vamp:unit "v" ; + vamp:default_value 0.005 ; + vamp:value_names (); + . +plugbase:vampy-zc2_output_vampy-counts a vamp:DenseOutput ; + vamp:identifier "vampy-counts" ; + dc:title "Number of Zero Crossings" ; + dc:description """Number of zero crossings per audio frame""" ; + vamp:fixed_bin_count "true" ; + vamp:unit " " ; + a vamp:QuantizedOutput ; + vamp:quantize_step 1 ; + vamp:bin_count 1 ; +# vamp:computes_event_type ; +# vamp:computes_feature ; +# vamp:computes_signal_type ; + . +plugbase:vampy-zc2_output_vampy-crossings a vamp:SparseOutput ; + vamp:identifier "vampy-crossings" ; + dc:title "Zero Crossing Locations" ; + dc:description """The locations of zero crossing points""" ; + vamp:fixed_bin_count "true" ; + vamp:unit "discrete" ; + vamp:bin_count 0 ; + vamp:sample_type vamp:VariableSampleRate ; +# vamp:computes_event_type ; +# vamp:computes_feature ; +# vamp:computes_signal_type ; + . + diff -r 44d56a3d16b7 -r f5b8646494d2 Makefile.linux --- a/Makefile.linux Mon Nov 17 11:44:15 2014 +0000 +++ b/Makefile.linux Mon Nov 17 12:53:51 2014 +0000 @@ -1,5 +1,9 @@ -CXXFLAGS := -DHAVE_NUMPY -O2 -Wall -Werror -fno-strict-aliasing -I/usr/include/python2.7 -I/usr/lib/python2.7/dist-packages/numpy/core/include -fPIC +CXXFLAGS := -DHAVE_NUMPY \ + -O2 -Wall -Werror -fno-strict-aliasing -fPIC \ + -I/usr/include/python2.7 \ + -I/usr/lib/python2.7/dist-packages/numpy/core/include + LDFLAGS := -shared -Wl,-Bstatic -lvamp-sdk -Wl,-Bdynamic -lpython2.7 -lpthread -Wl,--version-script=vamp-plugin.map default: vampy.so