From 211b3d9519f2d18d302b9915378b3a0919de40f7 Mon Sep 17 00:00:00 2001 From: knodlseder <> Date: Wed, 10 Aug 2011 06:30:25 +0000 Subject: [PATCH] do type conversion before parameter setting to make sure that the correct __setitem__ method gets called --- examples/make_ts_distributions.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/examples/make_ts_distributions.py b/examples/make_ts_distributions.py index 649cc19..1102e60 100755 --- a/examples/make_ts_distributions.py +++ b/examples/make_ts_distributions.py @@ -71,10 +71,10 @@ def create_ts(loge, emin, emax, ntrials=100, duration=180000.0, \ tsdist["index"] = -2.48 tsdist["offset"] = 0.0 tsdist["bkg"] = "$GAMMALIB/share/models/bkg_kb_E_50h_v3.txt" - tsdist["emin"] = emin - tsdist["emax"] = emax - tsdist["enumbins"] = enumbins - tsdist["duration"] = duration + tsdist["emin"] = float(emin) + tsdist["emax"] = float(emax) + tsdist["enumbins"] = int(enumbins) + tsdist["duration"] = float(duration) tsdist["rad"] = 5.0 tsdist["npix"] = 200 tsdist["binsz"] = 0.05 -- libgit2 0.21.4