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

Fix cube-arith possible problem in 'pearsonr'. #3621

Merged
merged 2 commits into from
Dec 20, 2019

Conversation

pp-mo
Copy link
Member

@pp-mo pp-mo commented Dec 20, 2019

This addresses the concern which is the last remaining unticked todo in #3554.

We are currently still uncertain what the exact behaviour of cube arithmetic will be in Iris 3.0.
In the absence of #3478, we have currently enabled cube.copy() to replicate cell measures, which means that certain operations no longer discard cell measures (or ancillaries).
This creates possible problems for some existing user code, and some internal code including this pearsonr routine.

In principle, #3618 will also fix this problem, but we may yet choose #3478 over that and we're not yet sure exactly what that will do.
So this change is a definite resolution of this small problem, irrespective of what we eventually choose to do about cube arithmetic generally.

@pp-mo pp-mo added this to In Progress in Iris v3.0.0 via automation Dec 20, 2019
@pp-mo pp-mo added this to the v3.0.0 milestone Dec 20, 2019
@pp-mo pp-mo moved this from In Progress to Waiting for Review in Iris v3.0.0 Dec 20, 2019
@pp-mo pp-mo changed the title Make '_ones_like' internal to 'pearsonr', and have it discard additional dim-metas. Fix cube-arith possible problem in 'pearsonr'. Dec 20, 2019
Iris v3.0.0 automation moved this from Waiting for Review to In Review Dec 20, 2019
Copy link
Contributor

@stephenworsley stephenworsley left a comment

Choose a reason for hiding this comment

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

Looks good.

@stephenworsley stephenworsley merged commit bad9fdf into SciTools:master Dec 20, 2019
Iris v3.0.0 automation moved this from In Review to Done Dec 20, 2019
@pp-mo pp-mo deleted the anc_safe_pearsonr branch January 6, 2020 00:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Iris v3.0.0
  
Done
Development

Successfully merging this pull request may close these issues.

None yet

2 participants