Commit 4303cb3d authored by Médéric Boquien's avatar Médéric Boquien

When determining the fluxes to compute, make sure we only try to access the...

When determining the fluxes to compute, make sure we only try to access the list of bands to analyse when that parameter is actually present in the analysis module.
parent 7d83a5c4
......@@ -37,10 +37,13 @@ class ModelsManager(object):
self.allintpropnames & props_nolog)
self.extpropnames = (self.allextpropnames & set(obs.extprops) |
self.allextpropnames & props_nolog)
if 'bands' in conf['analysis_params']:
bandnames = set(obs.bands+conf['analysis_params']['bands'])
else:
bandnames = obs.bands
size = len(params.blocks[iblock])
self.flux = {band: SharedArray(size)
for band in set(obs.bands+conf['analysis_params']['bands'])}
self.flux = {band: SharedArray(size) for band in bandnames}
self.intprop = {prop: SharedArray(size) for prop in self.intpropnames}
self.extprop = {prop: SharedArray(size) for prop in self.extpropnames}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment