Skip to content

Commit 31de76b

Browse files
committed
Allow inputs to be dicts in InvertMaps and RescaleMaps
1 parent 5b6cab4 commit 31de76b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

maps/python/map_modules.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -593,7 +593,7 @@ def InvertMaps(frame):
593593
"""
594594
Invert T, Q, U maps in the input map frame.
595595
"""
596-
if frame.type != core.G3FrameType.Map:
596+
if isinstance(frame, core.G3Frame) and frame.type != core.G3FrameType.Map:
597597
return
598598

599599
for k in "TQU":
@@ -647,7 +647,7 @@ def RescaleMaps(frame, t_scale=None, q_scale=None, u_scale=None, scale_weights=T
647647
If True, apply the appropriate scale factor to the weights as well.
648648
Otherwise the scale factors are only applied to the T/Q/U maps.
649649
"""
650-
if frame.type != core.G3FrameType.Map:
650+
if isinstance(frame, core.G3Frame) and frame.type != core.G3FrameType.Map:
651651
return
652652

653653
ValidateMaps(frame)

0 commit comments

Comments
 (0)