diff options
Diffstat (limited to 'fg21sim')
-rw-r--r-- | fg21sim/configs/10-galactic.conf.spec | 10 | ||||
-rw-r--r-- | fg21sim/galactic/freefree.py | 13 |
2 files changed, 4 insertions, 19 deletions
diff --git a/fg21sim/configs/10-galactic.conf.spec b/fg21sim/configs/10-galactic.conf.spec index 85cc8ee..cf2eef1 100644 --- a/fg21sim/configs/10-galactic.conf.spec +++ b/fg21sim/configs/10-galactic.conf.spec @@ -48,15 +48,13 @@ # Free-free bremsstrahlung emission component [[freefree]] - # The H{\alpha} map used as the free-free emission template + # The Hα map from which to derive the free-free emission + # Unit: [Rayleigh] halphamap = string(default=None) - # The unit of the H{\alpha} template (e.g., "Rayleigh") - halphamap_unit = string(default=None) - # The 100-{\mu}m dust map used for dust absorption correction + # The 100-μm dust map used to correct Hα dust absorption + # Unit: [MJy/sr] dustmap = string(default=None) - # The unit of the above dust map (e.g., "MJy/sr") - dustmap_unit = string(default=None) # Effective dust fraction in the LoS actually absorbing Halpha dust_fraction = float(default=0.33, min=0.1, max=1.0) diff --git a/fg21sim/galactic/freefree.py b/fg21sim/galactic/freefree.py index 16535ef..f14d9a7 100644 --- a/fg21sim/galactic/freefree.py +++ b/fg21sim/galactic/freefree.py @@ -30,7 +30,6 @@ import os import logging import numpy as np -import astropy.units as au from ..sky import get_sky @@ -77,11 +76,7 @@ class FreeFree: """ comp = self.compID self.halphamap_path = self.configs.get_path(comp+"/halphamap") - self.halphamap_unit = au.Unit( - self.configs.getn(comp+"/halphamap_unit")) self.dustmap_path = self.configs.get_path(comp+"/dustmap") - self.dustmap_unit = au.Unit( - self.configs.getn(comp+"/dustmap_unit")) self.f_dust = self.configs.getn(comp+"/dust_fraction") self.halpha_abs_th = self.configs.getn(comp+"/halpha_abs_th") # [mag] self.Te = self.configs.getn(comp+"/electron_temperature") # [K] @@ -100,16 +95,8 @@ class FreeFree: """ logger.info("Loading H[alpha] map ...") self.halphamap = self.sky.open(self.halphamap_path) - # Validate input map unit - if self.halphamap_unit != au.Unit("Rayleigh"): - raise ValueError("unsupported Halpha map unit: {0}".format( - self.halphamap_unit)) logger.info("Loading dust map ...") self.dustmap = self.sky.open(self.dustmap_path) - # Validate input map unit - if self.dustmap_unit != au.Unit("MJy / sr"): - raise ValueError("unsupported dust map unit: {0}".format( - self.dustmap_unit)) def _correct_dust_absorption(self): """ |