X-Git-Url: https://git.gag.com/?a=blobdiff_plain;ds=sidebyside;f=gr-utils%2Fsrc%2Fpython%2Fgr_plot_psd.py;fp=gr-utils%2Fsrc%2Fpython%2Fgr_plot_psd.py;h=0e3dbecd944f583d126364d76f215f244063d57d;hb=8a9ddbb0675f9bfcc6e03b457fba6c79474a3693;hp=669d7b573a4e0b6cfe5e0b0a8c98dadf41c26171;hpb=82d471b9b4a8b389b5da44b19c69c36420828382;p=debian%2Fgnuradio diff --git a/gr-utils/src/python/gr_plot_psd.py b/gr-utils/src/python/gr_plot_psd.py index 669d7b57..0e3dbecd 100755 --- a/gr-utils/src/python/gr_plot_psd.py +++ b/gr-utils/src/python/gr_plot_psd.py @@ -20,14 +20,6 @@ # Boston, MA 02110-1301, USA. # -try: - import matplotlib - matplotlib.use('TkAgg') - matplotlib.interactive(True) -except ImportError: - print "Please install Matplotlib to run this script (http://matplotlib.sourceforge.net/)" - raise SystemExit, 1 - try: import scipy from scipy import fftpack @@ -187,8 +179,9 @@ class gr_plot_psd: draw() def zoom(self, event): - newxlim = self.sp_iq.get_xlim() - if(newxlim.all() != self.xlim.all()): + newxlim = scipy.array(self.sp_iq.get_xlim()) + curxlim = scipy.array(self.xlim) + if(newxlim.all() != curxlim.all()): self.xlim = newxlim xmin = max(0, int(ceil(self.sample_rate*(self.xlim[0] - self.position)))) xmax = min(int(ceil(self.sample_rate*(self.xlim[1] - self.position))), len(self.iq))