예제 #1
0
    def __init__(self, pipeline):
        self.builder = gtk.Builder()
        src = pkgutil.get_data('timetag', 'hist.glade')
        self.builder.add_from_string(src)
        self.builder.connect_signals(self)
        self.win = self.builder.get_object('hist_window')
        self.win.connect('destroy', self.destroy_cb)
        self.pipeline = pipeline
        self.update_rate = 0.3  # Hz

        rc = config.load_rc()
        self.colors = {
            n: fix_color(chan.color)
            for (n, chan) in enumerate(rc['strobe-channels']) if chan.enabled
        }
        self.figure = Figure()
        self.axes = {}
        for n in self.colors:
            axes = self.figure.add_subplot(len(self.colors), 1, n + 1)
            axes.get_xaxis().set_major_formatter(
                matplotlib.ticker.ScalarFormatter(useOffset=False))
            self.axes[n] = axes

        canvas = self.__class__.FigureCanvas(self.figure)
        self.builder.get_object('plot_container').pack_start(canvas)
        self.win.show_all()
        ManagedBinner.__init__(self, self.pipeline, 'hist-plot')
예제 #2
0
        def __init__(self, pipeline):
                self.builder = gtk.Builder()
                src = pkgutil.get_data('timetag', 'hist.glade')
                self.builder.add_from_string(src)
                self.builder.connect_signals(self)
                self.win = self.builder.get_object('hist_window')
                self.win.connect('destroy', self.destroy_cb)
                self.pipeline = pipeline
                self.update_rate = 0.3 # Hz

                rc = config.load_rc()
                self.colors = {n: fix_color(chan.color)
                               for (n,chan) in enumerate(rc['strobe-channels'])
                               if chan.enabled
                               }
                self.figure = Figure()
                self.axes = {}
                for n in self.colors:
                        axes = self.figure.add_subplot(len(self.colors),1,n)
                        axes.get_xaxis().set_major_formatter(
                                        matplotlib.ticker.ScalarFormatter(useOffset=False))
                        self.axes[n] = axes

                canvas = self.__class__.FigureCanvas(self.figure)
                self.builder.get_object('plot_container').pack_start(canvas)
                self.win.show_all()
                ManagedBinner.__init__(self, self.pipeline, 'hist-plot')
예제 #3
0
    def __init__(self, pipeline):
        self.pipeline = pipeline
        self.builder = gtk.Builder()
        src = pkgutil.get_data("timetag", "fret_hist.glade")
        self.builder.add_from_string(src)
        self.builder.connect_signals(self)
        self.win = self.builder.get_object("hist_window")
        self.win.connect("destroy", self.destroy_cb)
        self.update_rate = 0.3  # Hz

        self.figure = Figure()
        self.axes = self.figure.add_subplot(111)
        self.axes.get_xaxis().set_major_formatter(matplotlib.ticker.ScalarFormatter(useOffset=False))

        canvas = self.__class__.FigureCanvas(self.figure)
        self.builder.get_object("plot_container").pack_start(canvas)
        self.win.show_all()
        ManagedBinner.__init__(self, self.pipeline, "fret-hist-plot")
예제 #4
0
        def __init__(self, pipeline):
                self.pipeline = pipeline
                self.builder = gtk.Builder()
                src = pkgutil.get_data('timetag', 'bin_series.glade')
                self.builder.add_from_string(src)
                self.builder.connect_signals(self)
                self.win = self.builder.get_object('bin_series_window')
                self.win.connect('destroy', self.destroy_cb)

                rc = config.load_rc()
                self.colors = map(lambda chan: fix_color(chan.color), rc['strobe-channels'])
                self.plot_update_rate = 12 # in Hertz
                self.y_bounds = None

                self.running = True
                self._setup_plot()
                self.win.show_all()
		ManagedBinner.__init__(self, self.pipeline, 'bin-series')
예제 #5
0
        def __init__(self, pipeline):
                self.pipeline = pipeline
                self.builder = gtk.Builder()
                src = pkgutil.get_data('timetag', 'bin_series.glade')
                self.builder.add_from_string(src)
                self.builder.connect_signals(self)
                self.win = self.builder.get_object('bin_series_window')
                self.win.connect('destroy', self.destroy_cb)

                rc = config.load_rc()
                self.colors = map(lambda chan: fix_color(chan.color), rc['strobe-channels'])
                self.plot_update_rate = 12 # in Hertz
                self.y_bounds = None

                self.running = True
                self._setup_plot()
                self.win.show_all()
		ManagedBinner.__init__(self, self.pipeline, 'bin-series')