Skip to content

Commit

Permalink
Fix bug #2981
Browse files Browse the repository at this point in the history
  • Loading branch information
pkhalaj committed Nov 19, 2024
1 parent c214917 commit b777de5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion satpy/readers/seviri_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -700,7 +700,7 @@ def calibrate(self, data, calibration):
"brightness_temperature"]:
gain, offset = self.get_gain_offset()
res = self._algo.convert_to_radiance(
data.astype(np.float32), gain, offset
data.astype(np.float32), np.float32(gain), np.float32(offset)
)
else:
raise ValueError(
Expand Down
1 change: 1 addition & 0 deletions satpy/tests/reader_tests/test_seviri_l1b_native.py
Original file line number Diff line number Diff line change
Expand Up @@ -1314,6 +1314,7 @@ def test_read_physical_seviri_nat_file(full_path):
with warnings.catch_warnings():
warnings.filterwarnings("ignore", category=UserWarning)
scene.load(["VIS006"])
assert scene["VIS006"].dtype == np.float32
assert scene["VIS006"].shape == (3712, 3712)
assert isinstance(scene["VIS006"], xr.core.dataarray.DataArray)

Expand Down

0 comments on commit b777de5

Please sign in to comment.