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

Mesh on mesh mapping fix #2390

Merged
merged 5 commits into from Mar 8, 2019

Conversation

Projects
None yet
3 participants
@rinkk
Copy link
Member

rinkk commented Feb 28, 2019

Adjusts the mesh on mesh mapping tool to use the functionality introduced in #2367

@@ -151,7 +134,7 @@ int main (int argc, char* argv[])
// maps the elevation of mesh nodes according to a ground truth mesh whenever nodes exist within max_dist
if (current_key == "-MESH")
{
if (argc < 5)
if (argc < 4)

This comment has been minimized.

@endJunction

endJunction Feb 28, 2019

Member

For another PR; this cli arguments handling could be upgraded to tclap.

This comment has been minimized.

@rinkk

rinkk Feb 28, 2019

Author Member

I know. However, this would require more time than I can currently spend on this. It's on the to-do list.

@endJunction
Copy link
Member

endJunction left a comment

Looks ok. Didn't check the details of the algorithm change in moveMeshNodes.cpp

{

/// Returns the element in which the given node is located when
/// projected onto a mesh, or nullptr if no such element was found.

This comment has been minimized.

@endJunction

endJunction Feb 28, 2019

Member

Doxygen hasn't finished yet, but the function documentation appears twice in the code, once here, once in the header file; it could be that it will show up twice in the doxygen's function documentation. Needs a quick check, when doxygen is done.

This comment has been minimized.

@rinkk

rinkk Feb 28, 2019

Author Member

Removed the duplicate comments.

@codecov

This comment has been minimized.

Copy link

codecov bot commented Feb 28, 2019

Codecov Report

Merging #2390 into master will increase coverage by 0.06%.
The diff coverage is 0%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2390      +/-   ##
==========================================
+ Coverage   32.72%   32.78%   +0.06%     
==========================================
  Files         529      530       +1     
  Lines       19957    19816     -141     
  Branches     9449     9302     -147     
==========================================
- Hits         6530     6496      -34     
+ Misses      10089     9966     -123     
- Partials     3338     3354      +16
Impacted Files Coverage Δ
MeshLib/MeshEditing/ProjectPointOnMesh.cpp 0% <0%> (ø)
MathLib/Vector3.cpp 33.33% <0%> (-33.34%) ⬇️
MeshLib/CoordinateSystem.cpp 42.85% <0%> (-14.29%) ⬇️
GeoLib/SimplePolygonTree.cpp 61.9% <0%> (-4.77%) ⬇️
GeoLib/AnalyticalGeometry-impl.h 72.95% <0%> (-4.1%) ⬇️
...eStepping/Algorithms/EvolutionaryPIDcontroller.cpp 68.18% <0%> (-3.04%) ⬇️
...ng/Algorithms/IterationNumberBasedTimeStepping.cpp 76.74% <0%> (-2.33%) ⬇️
GeoLib/Surface.cpp 56.81% <0%> (-2.28%) ⬇️
GeoLib/MinimalBoundingSphere.cpp 41.17% <0%> (-1.97%) ⬇️
GeoLib/Polyline.cpp 35.31% <0%> (-1.88%) ⬇️
... and 7 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 234e772...fa3e6f5. Read the comment docs.

@rinkk

This comment has been minimized.

Copy link
Member Author

rinkk commented Feb 28, 2019

The change to the algorithm is really simple: The utility used to assign the elevation of the closest point in the ground truth mesh to all nodes in the mesh to be mapped. Now, it using the actual elevation at the location of each node (that's the functionality introduced in the mesh2raster tool) and only if no point is found, it checks for the closest point within a user-specified radius (which is useful if boundaries are slightly translated due to different precision used in preprocessing tools).

@TomFischer
Copy link
Member

TomFischer left a comment

👍

@endJunction

This comment has been minimized.

Copy link
Member

endJunction commented Mar 6, 2019

@rinkk This needs a fix for an unused 'offset' variable in moveMeshNodes.cpp:144
https://jenkins.opengeosys.org/job/ufz/job/ogs/job/PR-2390/3/clang-mac/

@rinkk rinkk force-pushed the rinkk:meshmappingfix branch from 2b2ecac to fa3e6f5 Mar 8, 2019

@endJunction endJunction merged commit ec75045 into ufz:master Mar 8, 2019

4 of 5 checks passed

codecov/patch 0% of diff hit (target 32.72%)
Details
codecov/project 32.78% (+0.06%) compared to 234e772
Details
continuous-integration/jenkins/pr-merge This commit looks good
Details
deploy/netlify Deploy preview ready!
Details
ufz.ogs #20190308.12 succeeded
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.