ref: 14aae817e4c13ce56a40b83283bfb9c263e5a1c9
parent: 6b0ca87f82b439d4a4c37616731d995c726cd1f7
author: Paul Brossier <[email protected]>
date: Fri Jun 2 13:23:29 EDT 2006
ugly hack to plot beat track anyway ugly hack to plot beat track anyway
--- a/python/aubio/task/beat.py
+++ b/python/aubio/task/beat.py
@@ -192,14 +192,14 @@
import Gnuplot
oplots.append(Gnuplot.Data(results,with='linespoints',title="auto"))
- def plotplot(self,oplots,outplot=None):
+ def plotplot(self,wplot,oplots,outplot=None,extension=None,xsize=1.,ysize=1.,spectro=False):
import Gnuplot
- from aubio.gnuplot import gnuplot_init, audio_to_array, make_audio_plot
+ from aubio.gnuplot import gnuplot_create, audio_to_array, make_audio_plot
import re
# audio data
#time,data = audio_to_array(self.input)
#f = make_audio_plot(time,data)
- g = gnuplot_init(outplot)
+ g = gnuplot_create(outplot=outplot, extension=extension)
oplots = [Gnuplot.Data(self.gettruth(),with='linespoints',title="orig")] + oplots
g.plot(*oplots)
--- a/python/aubiocut
+++ b/python/aubiocut
@@ -133,7 +133,11 @@
ofunc = filetask.ofunc
lofunc.append(ofunc)
- if options.plot: filetask.plot(onsets, ofunc, wplot, oplots, nplot=options.nplot)
+ if options.plot:
+ if options.beat:
+ filetask.plot(oplots, onsets)
+ else:
+ filetask.plot(onsets, ofunc, wplot, oplots, nplot=options.nplot)
if options.func:
for i in ofunc: