Skip to content

Commit

Permalink
fix bug in eline pixelmask generation.
Browse files Browse the repository at this point in the history
  • Loading branch information
bd-j committed Jan 3, 2024
1 parent ede002a commit c15ccc2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion prospect/models/sedmodel.py
Original file line number Diff line number Diff line change
Expand Up @@ -458,7 +458,7 @@ def cache_eline_parameters(self, obs, nsigma=5, forcelines=False):
# This part has to go in every call
linewidth = nsigma * self._ewave_obs / ckms * self._eline_sigma_kms
pixel_mask = (np.abs(self._outwave - self._ewave_obs[:, None]) < linewidth[:, None])
pixel_mask = pixel_mask & obs.get("mask")[None, :]
pixel_mask = pixel_mask & obs.get("mask", np.ones_like(self._outwave))[None, :]
self._valid_eline = pixel_mask.any(axis=1) & self._use_eline

# --- wavelengths corresponding to valid lines ---
Expand Down

0 comments on commit c15ccc2

Please sign in to comment.