-
Notifications
You must be signed in to change notification settings - Fork 37
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
Refactor Mesh Constructors #1055
Conversation
…6/refactor-mesh-constructors
Passes |
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.
This is a nice cleanup. 👍 I don't know the answer about the function hooks so I defer to @pgrete on this one but what you did seems reasonable to me.
…6/refactor-mesh-constructors
…6/refactor-mesh-constructors
…6/refactor-mesh-constructors
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.
LGTM
|
It looks like the extended tests don't pass (any more?) |
Ah, there was a bug. I was mapping the derefinement counts based on the legacy logical location and then trying to find them based on the forest logical location (so effectively every derefinement count was set to zero). I think this wasn't showing up previously because the test was still setting a very high number for the derefinement_count until the latest PR was merged in. Should all be fixed now. |
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.
Further testing and debugging point towards the issue I'm seeing at scale being independent of this PR. So let's get this in as all other tests at smaller scale pass.
PR Summary
This PR splits up the
Mesh
constructors to remove code duplication between the regular and restart mesh constructors. The main rationale for doing this is to split up the constructors so that new constructors for non-hyper-rectangular meshes can easily be added.In the process of going through this PR, I noticed that some of the user function overrides were not set in the restart constructor. Someone please confirm that it is ok to set all of these on restart.
Almost all of the changes should be just a reorganization of pre-existing code. One exception is that on restart the base mesh is built from the parameter input file, and then the base mesh properties are checked against the restart file (as opposed to directly building from the restart file information). I think there is no reason why the parameter input should be able to change the mesh properties on restart, but please correct me if I am wrong.
PR Checklist