Skip to content

Commit

Permalink
fix np.float and np.str
Browse files Browse the repository at this point in the history
Replace np.float by np.float_ and np.str by np.str_, as that is very
likely what was intended.
  • Loading branch information
gerritholl committed Nov 24, 2022
1 parent e97803f commit d2e0bf3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion satpy/readers/aapp_mhs_amsub_l1c.py
Expand Up @@ -151,7 +151,7 @@ def _calibrate(data,
if calib_type == 'counts':
return channel

channel = channel.astype(np.float)
channel = channel.astype(np.float_)

return da.where(mask, channel, np.nan)

Expand Down
4 changes: 2 additions & 2 deletions satpy/tests/test_dataset.py
Expand Up @@ -327,7 +327,7 @@ def test_combine_dicts_close():
'b': 'foo',
'c': [1, 2, 3],
'd': {
'e': np.str('bar'),
'e': np.str_('bar'),
'f': datetime(2020, 1, 1, 12, 15, 30),
'g': np.array([1, 2, 3]),
},
Expand All @@ -340,7 +340,7 @@ def test_combine_dicts_close():
'b': 'foo',
'c': np.array([1, 2, 3]) + 1E-12,
'd': {
'e': np.str('bar'),
'e': np.str_('bar'),
'f': datetime(2020, 1, 1, 12, 15, 30),
'g': np.array([1, 2, 3]) + 1E-12
},
Expand Down

0 comments on commit d2e0bf3

Please sign in to comment.