-
Notifications
You must be signed in to change notification settings - Fork 30
Initial clipping code re-factor #1667
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
base: develop
Are you sure you want to change the base?
Conversation
… into feature/gunney/initial-mesh-clipper
With CoordinateTransformer, we don't need this code anymore.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I found a few typos and unclear spots, a possible data write conflict within a loop, and a need for refactoring three methods down to one. Let's chat about the loop: perhaps I don't understand what is going on well enough.
The refactoring three methods to one needs to happen, but we can do it when this gets moved out of experimental namespace.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@gunney1 , I appreciate your work on this, and your fixes. As we discussed, there is work to be done in a future PR. This one looks to be in a good shape.
Summary
This PR is an initial refactoring of the clipping code in
IntersectionShaper.IntersectionShaperhas 4 significant jobs that make it big and a bit unwieldy.IntersectionShaperto use.This PR
IntersectionShaper. The idea is to eventually remove theIntersectionShaper's clipping code and use the new clipping code instead.ArrayViewobjects, regardless of whether the mesh is Blueprint or MFEM, and stored in Sidre or Conduit. This part is a work-in-progress in that MFEM support has not started.Completed work
MeshClipperclass provides the access point for the clipping functionality.MeshClipper::clipcomputes the overlap volume for every cell in the mesh.MeshClipper::clipmethod uses fast geometry-specific operations where they are available and falls back on a general method where they aren't.IntersectionShaper. This general method is the only choice when using the currentIntersectionShaper.MeshClipperImpl, a class templated on execution-space . This class containscomputeClipVolumed3D, the code taken fromIntersectionShaper. The two other versions of this method do the same thing but on a subset of cells or tets (from cells) that excludes those outside or inside the geometry.MeshClipperStrategy.ShapeMeshencapsulates the mesh being shaped into. It provides a uniform interface for accessing the mesh data, regardless of whether the data is stored in Conduit or Sidre or by blueprint or (future) MFEM convention.ShapeMeshalso computes and caches a variety of mesh-dependent data to amortize their cost among all clipping geometries.MeshClipper.New codes are in
namespace experimental, because this is a work in progress.Dependencies
The mesh clipping refactor includes multiple PRs. Please review these before this one.