Skip to content

Commit

Permalink
np.int is obsolete - replaced by built-in int function
Browse files Browse the repository at this point in the history
  • Loading branch information
mollyhardman committed Aug 15, 2024
1 parent 4cd3c4a commit 76c1a27
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions python/correct_time_coverage.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ def usage():
endmin = np.max(tb_time)
time_units = ds.variables['TB_time'].units
dd = datetime.strptime(time_units, "minutes since %Y-%m-%d %H:%M:%S")
startdd = dd + timedelta(minutes=np.int(startmin))
enddd = dd + timedelta(minutes=np.int(endmin))
startdd = dd + timedelta(minutes=int(startmin))
enddd = dd + timedelta(minutes=int(endmin))
start_string="%d-%02d-%02dT%02d:%02d:%02d.00Z" % (startdd.year, startdd.month, startdd.day, startdd.hour, startdd.minute, startdd.second)
end_string="%d-%02d-%02dT%02d:%02d:%02d.00Z" % (enddd.year, enddd.month, enddd.day, enddd.hour, enddd.minute, enddd.second)
ds.setncattr('time_coverage_start', start_string)
Expand Down

0 comments on commit 76c1a27

Please sign in to comment.