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

Documentation says that some operators can work on ONLY ONE dataset, when they can work on ensembles #223

Open
jypeter opened this issue Oct 6, 2021 · 2 comments

Comments

@jypeter
Copy link

jypeter commented Oct 6, 2021

I have followed the documentation links from the Standard operators and functions page, and the current documentation for some operators says that they can have only one input. The way I understand this is that they can be applied to a dataset, but not to an ensemble:

Doc says: Inputs [...] any dataset (but only one)

Examples:

Either the documentation is slightly out of date, or the ambiguity could be clarified

I have checked below that time_average could be successfully applied to an ensemble

# My test ensemble
>>> all_ens_dic['exp_ens'].keys()
dict_keys(['AWI-ESM-1-1-LR_AWI', 'CESM2_NCAR', 'FGOALS-f3-L_CAS', 'GISS-E2-1-G_NASA-GISS', 'HadGEM3-GC31-LL_NERC', 'INM-CM4-8_INM', 'IPSL-CM6A-LR_IPSL', 'MIROC-ES2L_MIROC', 'MPI-ESM1-2-LR_MPI-M', 'MRI-ESM2-0_MRI', 'NESM3_NUIST', 'NorESM1-F_NCC'])

# A member
>>> all_ens_dic['exp_ens']['FGOALS-f3-L_CAS']
ds('CMIP6%%pr%1120-1219%global%/bdd%FGOALS-f3-L%CAS%PMIP%Amon%midHolocene%r1i1p1f1%gr%latest')

# The member crs I get after applying time_average to the ensemble
>>> tt = time_average(all_ens_dic['exp_ens'])
>>> tt['FGOALS-f3-L_CAS']
time_average(ds('CMIP6%%pr%1120-1219%global%/bdd%FGOALS-f3-L%CAS%PMIP%Amon%midHolocene%r1i1p1f1%gr%latest'))
@senesis
Copy link
Collaborator

senesis commented Oct 6, 2021

Yes. The wow feature that allows to automatically loop on ensemble members when operators accepts only a member should be quoted in the doc, there

@jypeter
Copy link
Author

jypeter commented Oct 7, 2021

cscalar has no magic feature yet (#222)

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

No branches or pull requests

2 participants