Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ajout nb variabilite interannelle #7

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

ajout nb variabilite interannelle #7

wants to merge 2 commits into from

Conversation

martinleduc
Copy link
Collaborator

No description provided.

@martinleduc martinleduc self-assigned this Dec 20, 2024
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@@ -35,17 +35,14 @@
"\n",
Copy link
Collaborator

@tlogan2000 tlogan2000 Jan 8, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line #3.    ds = xr.open_dataset(url, chunks={"time": -1, "lat": 50, "lon": 50})

Missed this before but this time chunking could potentially cause issues if used in more advanced calculations or on longer time series

Suggestion : chunks={"time": (365*4)+1, "lat": 50, "lon": 50}

This has become a pretty standard chunk size on PAVICS datasets (4 years in time and 50, 50 in spatial dims)


Reply via ReviewNB

Copy link

review-notebook-app bot commented Jan 8, 2025

View / edit / reply to this conversation on ReviewNB

tlogan2000 commented on 2025-01-08T14:58:07Z
----------------------------------------------------------------

Line #3.    ds = xr.open_dataset(url, chunks={"time": -1, "lat": 50, "lon": 50})

Suggest to change chunks to the same as mentioned in comment added to the 'Climate Average' notebook


Copy link

review-notebook-app bot commented Jan 8, 2025

View / edit / reply to this conversation on ReviewNB

tlogan2000 commented on 2025-01-08T14:58:08Z
----------------------------------------------------------------

Line #2.    std_ann = tas_region.resample(time='YE').mean().std(dim='time',ddof=1)

Use time=YS (year-start) here instead. The time=YE (year end) frequency will potentially cause problems if code is eventually applied to climate simulations with a mix of 360_day and other calendars (time coord anchor point will be 12-30 for 360day and 12-31 for the rest). Combining data in an ensemble will then be problematic as time coord do not align.

In this case nothing changes (and even here the output has no time dim) but this just avoids potential confusion elsewhere if people get used to using 'YS' (or 'MS', 'QS-DEC' etc) as a default.


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants