[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Commit-gnuradio] r11290 - gnuradio/branches/developers/trondeau/pfb/gr-
From: |
trondeau |
Subject: |
[Commit-gnuradio] r11290 - gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python |
Date: |
Thu, 25 Jun 2009 19:48:03 -0600 (MDT) |
Author: trondeau
Date: 2009-06-25 19:48:02 -0600 (Thu, 25 Jun 2009)
New Revision: 11290
Modified:
gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/gr_plot_const.py
gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/gr_plot_fft.py
gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/gr_plot_iq.py
gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/gr_plot_psd.py
gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/plot_data.py
Log:
Fixing problem with the .all(). Seems Matplotlib-specific; getting around this
by forcing it to a numpy.array().
Modified:
gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/gr_plot_const.py
===================================================================
---
gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/gr_plot_const.py
2009-06-26 01:18:16 UTC (rev 11289)
+++
gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/gr_plot_const.py
2009-06-26 01:48:02 UTC (rev 11290)
@@ -35,9 +35,6 @@
from optparse import OptionParser
-matplotlib.interactive(True)
-matplotlib.use('TkAgg')
-
class draw_constellation:
def __init__(self, filename, options):
self.hfile = open(filename, "r")
@@ -139,8 +136,9 @@
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
r = self.reals[int(ceil(self.xlim[0])) : int(ceil(self.xlim[1]))]
i = self.imags[int(ceil(self.xlim[0])) : int(ceil(self.xlim[1]))]
Modified:
gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/gr_plot_fft.py
===================================================================
---
gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/gr_plot_fft.py
2009-06-26 01:18:16 UTC (rev 11289)
+++
gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/gr_plot_fft.py
2009-06-26 01:48:02 UTC (rev 11290)
@@ -21,14 +21,6 @@
#
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
except ImportError:
@@ -164,8 +156,9 @@
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))
Modified:
gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/gr_plot_iq.py
===================================================================
--- gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/gr_plot_iq.py
2009-06-26 01:18:16 UTC (rev 11289)
+++ gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/gr_plot_iq.py
2009-06-26 01:48:02 UTC (rev 11290)
@@ -34,10 +34,7 @@
from optparse import OptionParser
-matplotlib.interactive(True)
-matplotlib.use('TkAgg')
-
-class draw_fft:
+class draw_iq:
def __init__(self, filename, options):
self.hfile = open(filename, "r")
self.block_length = options.block
@@ -168,7 +165,7 @@
raise SystemExit, 1
filename = args[0]
- dc = draw_fft(filename, options)
+ dc = draw_iq(filename, options)
if __name__ == "__main__":
try:
Modified:
gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/gr_plot_psd.py
===================================================================
---
gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/gr_plot_psd.py
2009-06-26 01:18:16 UTC (rev 11289)
+++
gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/gr_plot_psd.py
2009-06-26 01:48:02 UTC (rev 11290)
@@ -21,14 +21,6 @@
#
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
except ImportError:
@@ -187,8 +179,9 @@
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))
Modified:
gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/plot_data.py
===================================================================
--- gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/plot_data.py
2009-06-26 01:18:16 UTC (rev 11289)
+++ gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python/plot_data.py
2009-06-26 01:48:02 UTC (rev 11290)
@@ -33,9 +33,6 @@
from optparse import OptionParser
-matplotlib.interactive(True)
-matplotlib.use('TkAgg')
-
class plot_data:
def __init__(self, datatype, filenames, options):
self.hfile = list()
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Commit-gnuradio] r11290 - gnuradio/branches/developers/trondeau/pfb/gr-utils/src/python,
trondeau <=