From d9745b0203a8fe052b217fa6fe6e59a99d6c7d2f Mon Sep 17 00:00:00 2001 From: LukasK13 Date: Tue, 30 Jun 2020 10:25:47 +0200 Subject: [PATCH] Add wl_bins to configuration --- esbo_etc/classes/Config.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/esbo_etc/classes/Config.py b/esbo_etc/classes/Config.py index 4cac017..cf09d12 100644 --- a/esbo_etc/classes/Config.py +++ b/esbo_etc/classes/Config.py @@ -93,7 +93,8 @@ class Configuration(object): if hasattr(self.conf.common, "wl_delta"): wl_delta = self.conf.common.wl_delta() else: - wl_delta = self.conf.common.wl_min() / self.conf.common.res() + wl_delta = (self.conf.common.wl_min() + self.conf.common.wl_max()) / (2 * self.conf.common.res()) + setattr(self.conf.common, 'wl_delta', Entry(val=wl_delta)) setattr(self.conf.common, 'wl_bins', Entry(val=np.append(np.arange(self.conf.common.wl_min().to(u.nm).value, self.conf.common.wl_max().to(u.nm).value, wl_delta.to(u.nm).value),