Conversation
…the grid and then interpolate to the nodes using this. For this commit I split the interpolation into a weight calculation (InterpFromMeshToMesh2dx_weights) and their application (InterpFromMeshToMesh2dx_apply). The weight calculation can be done only when remeshing, saving hopefully substantial processing time.
…ecalculation within the ExternalData check_and_reload function by setting a flag (calc_nodal_weights = true) in the DataSet object. Plus a good number of fixes
…ghts Conflicts: model/dataset.cpp
… me understand what was happening in the first place.
…ghts Conflicts: model/externaldata.cpp
tdcwilliams
approved these changes
Aug 13, 2020
Contributor
tdcwilliams
left a comment
There was a problem hiding this comment.
seems good. Some minor changes you could put in.
| I2 I=Th->R2ToI2(r); | ||
|
|
||
| /*Find triangle holding r/I*/ | ||
| Triangle &tb=*Th->TriangleFindFromCoord(I,dete); |
Contributor
There was a problem hiding this comment.
is there ever any problem with this? I have had trouble with points that are already on the nodes of the mesh in the past
Member
Author
There was a problem hiding this comment.
I've never seen that problem. Can you reproduce it?
Member
Author
There was a problem hiding this comment.
But it's the same result as from InterpFromMeshToMesh anyway - I just split the function so that we don't have to calculate the weight every timestep.
Contributor
There was a problem hiding this comment.
Don't worry about it then. I haven't tried to do it in a while - had trouble interp'ing from elements to nodes in the WIM
Co-authored-by: Timothy Williams <tdcwilliams@gmail.com>
Co-authored-by: Timothy Williams <tdcwilliams@gmail.com>
Co-authored-by: Timothy Williams <tdcwilliams@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Address issue #369 by splitting interpFromMeshToMesh into weight calculation (done at remeshing) and application (done every time step). This is only used for the coupler at the moment, although we could probably save some time by using it also for high time resolution forcing datasets (like ERA5).