From: Arnold M. <arn...@wu...> - 2004-03-04 08:31:52
|
Hi all, I encountered a strange error (which I now remember was there already in version 0.50). When I run (for example) the mathtext_demo.py, I get the following error: <error> File "/usr/lib/python2.3/site-packages/matplotlib/backends/backend_gtk.py", line 504, in points_to_pixels return points*PIXELS_PER_INCH/72.0*self.dpi.get()/72.0 TypeError: unsupported operand type(s) for /: 'array' and 'float' </error> When I replace that line 504 with (note the parentheses) return points*(PIXELS_PER_INCH/72.0*self.dpi.get()/72.0) python is happy. I don't understand why python doesn't like the present construct. Possibly an odd combination of versions: -> Python 2.3 (#2, Aug 31 2003, 17:27:29) [GCC 3.3.1 (Mandrake Linux 9.2 3.3.1-1mdk)] on linux2 -> Numeric 22.0 -> scipy cvs_version = (1,196,1591,4120) Cheers, Arnold PS: the mathtext-option was a very pleasant surprise to me (hadn't seen any discussion on it on the mailing list). |