Skip to content

Commit

Permalink
fix: use beam only if specified
Browse files Browse the repository at this point in the history
  • Loading branch information
zonca committed Oct 15, 2024
1 parent 9f80be5 commit da10261
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion mapsims/channel_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,11 @@ def parse_channels(filter="all", instrument_parameters=None):
if name not in ["band", "tag", "fwhm", "telescope", "tube"]
}

try:
other_metadata["custom_beam"] = beam["B"]
except UnboundLocalError:
pass

channel_objects_list.append(
Channel(
tag=tag,
Expand All @@ -190,7 +195,6 @@ def parse_channels(filter="all", instrument_parameters=None):
bandpass["bandpass_weight"],
),
beam=row["fwhm"],
custom_beam=beam["B"],
telescope=telescope,
tube=tube,
**other_metadata,
Expand Down

0 comments on commit da10261

Please sign in to comment.