Skip to content

Commit

Permalink
Update ARGOS_service_data_converter.py
Browse files Browse the repository at this point in the history
  • Loading branch information
shaunwbell committed Dec 10, 2024
1 parent 4dd04d9 commit a5e0a80
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions ARGOS_service_data_converter.py
Original file line number Diff line number Diff line change
Expand Up @@ -479,6 +479,11 @@ def pandas2netcdf(df=None, ofile="data.nc",isxa=True):
pass
else:
pass

#xarray casting issue?
for var in xdf.variables:
if xdf[var].dtype == 'float64':
xdf[var] = xdf[var].astype('float32')

#global attributes
xdf.attrs["CREATION_DATE"] = datetime.now(timezone.utc).strftime("%B %d, %Y %H:%M UTC")
Expand Down

0 comments on commit a5e0a80

Please sign in to comment.