From 3565f166269b454760058f165dfdc0ec437f54ae Mon Sep 17 00:00:00 2001 From: Jürgen Knödlseder Date: Fri, 9 Jun 2017 14:24:45 +0200 Subject: [PATCH] Add Python 3.x kluge to csresmap script (missing Python 3.x division operator in GammaLib) --- cscripts/csresmap.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cscripts/csresmap.py b/cscripts/csresmap.py index 6acbb9e..2e0c380 100755 --- a/cscripts/csresmap.py +++ b/cscripts/csresmap.py @@ -247,7 +247,9 @@ class csresmap(ctools.cscript): signmap = (self._resmap - modelmap).sign() # Compute logarithm of map. For that we mask pixels - logmap = self._resmap/modelmap + #logmap = self._resmap/modelmap + logmap = self._resmap.copy() # Python 3.x kluge + logmap /= modelmap for i in range(logmap.npix()): if logmap[i] > 0.0: logmap[i] = math.log(logmap[i]) -- libgit2 0.21.4