From: <md...@us...> - 2010-10-19 12:44:20
|
Revision: 8755 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8755&view=rev Author: mdboom Date: 2010-10-19 12:44:14 +0000 (Tue, 19 Oct 2010) Log Message: ----------- Make is_decade safe for non-finite values. Modified Paths: -------------- branches/v1_0_maint/lib/matplotlib/ticker.py Modified: branches/v1_0_maint/lib/matplotlib/ticker.py =================================================================== --- branches/v1_0_maint/lib/matplotlib/ticker.py 2010-10-15 13:34:49 UTC (rev 8754) +++ branches/v1_0_maint/lib/matplotlib/ticker.py 2010-10-19 12:44:14 UTC (rev 8755) @@ -1187,6 +1187,8 @@ else: return long(x-0.5) def is_decade(x, base=10): +y if not np.isfinite(x): + return False if x == 0.0: return True lx = math.log(x)/math.log(base) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |