Skip to content

Remove result_fa from interp_to - #1427

Merged
johnomotani merged 2 commits into
nextfrom
remove-result_fa-from-interp-to
Dec 15, 2018
Merged

Remove result_fa from interp_to#1427
johnomotani merged 2 commits into
nextfrom
remove-result_fa-from-interp-to

Conversation

@johnomotani

Copy link
Copy Markdown
Contributor

Remove the intermediate variable result_fa in branch of interp_to that transforms to field-aligned variables. Just store the intermediate result in 'result' instead, to save memory.

This commit was previously part of #1176, but isn't really related and it looks like #1176 won't be merged (at least in its current form).

Comment thread src/mesh/interpolation.cxx Outdated
Field3D result_fa(fieldmesh);
if (region != RGN_NOBNDRY) {
result_fa = fieldmesh->toFieldAligned(result);
result = fieldmesh->toFieldAligned(result);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Should this be result = var_fa to save duplicate toFieldAligned calls (my understanding is that result=var in this situation)?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

You're right 👍 I think the behaviour we are supporting at this point is a bug, but that's a separate issue (#1430).

Remove the intermediate variable result_fa in branch of interp_to that
transforms to field-aligned variables. Just store the intermediate
result in 'result' instead, to save memory.
@johnomotani
johnomotani force-pushed the remove-result_fa-from-interp-to branch from f05a293 to 1d3f032 Compare December 10, 2018 15:58
@johnomotani
johnomotani merged commit 63736ff into next Dec 15, 2018
@johnomotani
johnomotani deleted the remove-result_fa-from-interp-to branch December 15, 2018 20:01
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