[hdf-compass] 243/295: Disable ShadedRelief for matplolib < 1.5

Ghislain Vaillant ghisvail-guest at moszumanska.debian.org
Sun May 8 10:35:50 UTC 2016


This is an automated email from the git hooks/post-receive script.

ghisvail-guest pushed a commit to branch debian/master
in repository hdf-compass.

commit afcdea9e26d4c7cd8d6dd03c636eca613401ffa3
Author: giumas <giumas at yahoo.it>
Date:   Sat Nov 7 15:54:17 2015 -0500

    Disable ShadedRelief for matplolib < 1.5
---
 hdf_compass/bag_model/model.py      | 5 +++++
 hdf_compass/compass_viewer/frame.py | 4 ++--
 setup.py                            | 2 +-
 3 files changed, 8 insertions(+), 3 deletions(-)

diff --git a/hdf_compass/bag_model/model.py b/hdf_compass/bag_model/model.py
index 8dcf2ef..fb6d9e1 100644
--- a/hdf_compass/bag_model/model.py
+++ b/hdf_compass/bag_model/model.py
@@ -380,6 +380,11 @@ class BAGElevation(compass_model.GeoSurface):
 
     @staticmethod
     def can_handle(store, key):
+        import matplotlib
+        # for GeoSurface we are using a matplotlib function present after 1.5.x
+        plt_maj, plt_min, _ = matplotlib.__version__.split('.')
+        if (int(plt_maj) == 1) and (int(plt_min) < 5):
+            return False
         return (key == "/BAG_root/elevation") and (key in store) and (isinstance(store.f[key], h5py.Dataset))
 
     def __init__(self, store, key):
diff --git a/hdf_compass/compass_viewer/frame.py b/hdf_compass/compass_viewer/frame.py
index 1d0ffdf..50ffbe2 100644
--- a/hdf_compass/compass_viewer/frame.py
+++ b/hdf_compass/compass_viewer/frame.py
@@ -467,8 +467,8 @@ class PluginInfoFrame(wx.Frame):
 
         for store in compass_model.get_stores():
             try:
-                print(store.plugin_name())
-                print(store.plugin_description())
+                # log.debug(store.plugin_name())
+                # log.debug(store.plugin_description())
 
                 pnl = wx.Panel(nb)
                 t = rtc.RichTextCtrl(pnl, -1, style=wx.TE_READONLY)
diff --git a/setup.py b/setup.py
index 17a19ed..0207f49 100644
--- a/setup.py
+++ b/setup.py
@@ -103,7 +103,7 @@ setup_args['setup_requires'] =\
 setup_args['install_requires'] =\
     [
         "numpy",
-        "matplotlib",
+        "matplotlib>=1.5",
         "cartopy",
         "h5py",
         "wxPython",

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/hdf-compass.git



More information about the debian-science-commits mailing list