I am using Matplotlib version 1.0.1 and I get errors if I try the following:
import matplotlib.pyplot as plt import numpy as np plt.specgram(np.zeros(50)) I have pasted the error output below, but hopefully it would reproduce in other systems. I'm not sure if this is intended behavior and was wondering. I came across this when I was plotting the specgram of my sound input, but my microphone was muted! --------------------------------------------------------------------------- AttributeError Traceback (most recent call last) /usr/local/lib/python2.6/dist-packages/matplotlib/backends/backend_wx.pyc in _onPaint(self, evt) 1192 drawDC = wx.PaintDC(self) 1193 if not self._isDrawn: -> 1194 self.draw(drawDC=drawDC) 1195 else: 1196 self.gui_repaint(drawDC=drawDC) /usr/local/lib/python2.6/dist-packages/matplotlib/backends/backend_wxagg.pyc in draw(self, drawDC) 57 """ 58 DEBUG_MSG("draw()", 1, self) ---> 59 FigureCanvasAgg.draw(self) 60 61 self.bitmap = _convert_agg_to_wx_bitmap(self.get_renderer(), None) /usr/local/lib/python2.6/dist-packages/matplotlib/backends/backend_agg.pyc in draw(self) 392 393 self.renderer = self.get_renderer() --> 394 self.figure.draw(self.renderer) 395 396 def get_renderer(self): /usr/local/lib/python2.6/dist-packages/matplotlib/artist.pyc in draw_wrapper(artist, renderer, *args, **kwargs) 53 def draw_wrapper(artist, renderer, *args, **kwargs): 54 before(artist, renderer) ---> 55 draw(artist, renderer, *args, **kwargs) 56 after(artist, renderer) 57 /usr/local/lib/python2.6/dist-packages/matplotlib/figure.pyc in draw(self, renderer) 796 dsu.sort(key=itemgetter(0)) 797 for zorder, func, args in dsu: --> 798 func(*args) 799 800 renderer.close_group('figure') /usr/local/lib/python2.6/dist-packages/matplotlib/artist.pyc in draw_wrapper(artist, renderer, *args, **kwargs) 53 def draw_wrapper(artist, renderer, *args, **kwargs): 54 before(artist, renderer) ---> 55 draw(artist, renderer, *args, **kwargs) 56 after(artist, renderer) 57 /usr/local/lib/python2.6/dist-packages/matplotlib/axes.pyc in draw(self, renderer, inframe) 1944 1945 for zorder, a in dsu: -> 1946 a.draw(renderer) 1947 1948 renderer.close_group('axes') /usr/local/lib/python2.6/dist-packages/matplotlib/artist.pyc in draw_wrapper(artist, renderer, *args, **kwargs) 53 def draw_wrapper(artist, renderer, *args, **kwargs): 54 before(artist, renderer) ---> 55 draw(artist, renderer, *args, **kwargs) 56 after(artist, renderer) 57 /usr/local/lib/python2.6/dist-packages/matplotlib/image.pyc in draw(self, renderer, *args, **kwargs) 352 warnings.warn("Image will not be shown correctly with this backend.") 353 --> 354 im = self.make_image(renderer.get_image_magnification()) 355 if im is None: 356 return /usr/local/lib/python2.6/dist-packages/matplotlib/image.pyc in make_image(self, magnification) 567 im, xmin, ymin, dxintv, dyintv, sx, sy = \ 568 self._get_unsampled_image(self._A, [_x1, _x2, _y1, _y2], --> 569 transformed_viewLim) 570 571 fc = self.axes.patch.get_facecolor() /usr/local/lib/python2.6/dist-packages/matplotlib/image.pyc in _get_unsampled_image(self, A, image_extents, viewlim) 199 else: 200 if self._rgbacache is None: --> 201 x = self.to_rgba(self._A, self._alpha) 202 self._rgbacache = x 203 else: /usr/local/lib/python2.6/dist-packages/matplotlib/cm.pyc in to_rgba(self, x, alpha, bytes) 191 pass 192 x = ma.asarray(x) --> 193 x = self.norm(x) 194 x = self.cmap(x, alpha=alpha, bytes=bytes) 195 return x /usr/local/lib/python2.6/dist-packages/matplotlib/colors.pyc in __call__(self, value, clip) 809 if vmin > vmax: 810 raise ValueError("minvalue must be less than or equal to maxvalue") --> 811 elif vmin==vmax: 812 result = 0.0 * val 813 else: /usr/lib/python2.6/dist-packages/numpy/ma/core.pyc in __eq__(self, other) 3117 mask = np.all([[f[n].all() for n in mask.dtype.names] 3118 for f in mask], axis=axis) -> 3119 check._mask = mask 3120 return check 3121 # AttributeError: 'numpy.bool_' object has no attribute '_mask' ------------------------------------------------------------------------------ Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl _______________________________________________ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users