Skip to content

Commit

Permalink
Fix precip from ERA5
Browse files Browse the repository at this point in the history
  • Loading branch information
b8raoult committed Dec 28, 2023
1 parent 023e653 commit cb99db1
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 6 deletions.
2 changes: 1 addition & 1 deletion ai_models_graphcast/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@
# granted to it by virtue of its status as an intergovernmental organisation
# nor does it submit to any jurisdiction.

__version__ = "0.0.4"
__version__ = "0.0.5"
18 changes: 13 additions & 5 deletions ai_models_graphcast/output.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,16 @@ def save_output_xarray(

values = np.flipud(values.reshape(fs.shape))

write(
values,
template=fs,
step=(time + 1) * hour_steps,
)
if param == "total_precipitation_6hr":
write(
values,
template=fs,
startStep=0,
endStep=(time + 1) * hour_steps,
)
else:
write(
values,
template=fs,
step=(time + 1) * hour_steps,
)

0 comments on commit cb99db1

Please sign in to comment.