Commit 25483cf0 authored by Médéric Boquien's avatar Médéric Boquien

It is not necessary to explicitly call keys() when iterating over a dictionary.

parent e48a3853
......@@ -120,11 +120,11 @@ def sed(idx, midx):
gbl_models.intprop[prop][idx] = np.nan
else:
for band in gbl_models.flux.keys():
for band in gbl_models.flux:
gbl_models.flux[band][idx] = sed.compute_fnu(band)
for prop in gbl_models.extprop.keys():
for prop in gbl_models.extprop:
gbl_models.extprop[prop][idx] = sed.info[prop]
for prop in gbl_models.intprop.keys():
for prop in gbl_models.intprop:
gbl_models.intprop[prop][idx] = sed.info[prop]
gbl_counter.inc()
......
......@@ -70,11 +70,11 @@ def fluxes(idx, midx):
for prop in gbl_models.intprop:
gbl_models.intprop[prop][idx] = np.nan
else:
for band in gbl_models.flux.keys():
for band in gbl_models.flux:
gbl_models.flux[band][idx] = sed.compute_fnu(band)
for prop in gbl_models.extprop.keys():
for prop in gbl_models.extprop:
gbl_models.extprop[prop][idx] = sed.info[prop]
for prop in gbl_models.intprop.keys():
for prop in gbl_models.intprop:
gbl_models.intprop[prop][idx] = sed.info[prop]
if gbl_save is True:
......
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