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

Exaconstit dev 4.0rc1 #1

Merged
merged 751 commits into from
Apr 25, 2019
Merged

Exaconstit dev 4.0rc1 #1

merged 751 commits into from
Apr 25, 2019

Conversation

rcarson3
Copy link
Owner

@rcarson3 rcarson3 commented Apr 24, 2019

I'm a little hesitant to merge the MFEM v4.0rc1 changes into the current ExaConstit branch. The reasons are that I'm finding some minor inconsistencies between the calculated residual for the initial time step even though nothing has changed within the ExaConstit framework. I'm also seeing differences in the outputted average stress tensor, but I'm pretty sure this more related to the difference in the residuals causing the solutions to be slightly different.

Here's an example from a small simulation of 1000 elements.

New version:

inside timestep loop 1
Newton iteration  0 : ||r|| = 10.7495

Old version:

inside timestep loop 1
Newton iteration  0 : ||r|| = 10.8017

I'm going to run a larger production run to see what the differences look like there before moving things forward.

edit: I finished one of the production runs, and the difference in that initial residual definitely had a larger effect by 1% strain.

Final average stress state master as of :

3.36458e-08 3.45394e-08 112.697 0.955912 1.09585 0.498297

Final average stress state v4rc1 branch:

7.22825e-09 7.31903e-09 121.014 0.2003 -0.0653882 -0.195267

camierjs and others added 30 commits March 20, 2019 11:23
Describe limitation of this operator when applied to H1 finite element spaces.
[okina] Adjustments to Okina's Atomics [artv3/okina/atomic-fix]
Re-introduce DeviceVector3 class
Remove the mutable from MFEM_FORALL
Simplified the dtensor class
camierjs and others added 22 commits April 10, 2019 10:41
Okina fallback kernels [okina-fallback-kernels]
Okina mm object [okina-mm-object]
Small updates in ex1, ex1p, ex6, ex6p.
Lambda const propagation [lambda-capture-problem]
Updates in the examples, class BilinearForm and related [okina-bilinearform-updates]
Release candidate #1 for version 4.0
@tzanio
Copy link
Collaborator

tzanio commented Apr 24, 2019

Compared to the previous release there have been several changes, not related to GPU/device support, that could introduce round-off level differences.

Can you check the results with the pre-okina tag? This is right before the okina branch merge.

Can you also provide more details about the problem you are solving? For example there have been some substantial changes in mesh refinement...

FYI, we just tagged v4.0rc2: https://github.com/mfem/mfem/releases/tag/v4.0-rc2

@rcarson3
Copy link
Owner Author

rcarson3 commented Apr 24, 2019

I'll take a look at the pre-okina tag, and see if any changes since I last merged in changes from the master branch around the middle of January are causing the differences.

The PDE I'm solving is simply Div \sigma = 0 where \sigma is the Cauchy stress. The difference here between what I'm working with and a simple linear elastic problem is that I'm now dealing with an elasto-viscoplastic crystal plasticity problem where I've got multiple grains in my domain which leads to a nonlinear, (typically) nonuniform stress response.

Furthermore, I'm applying symmetry boundary conditions which means I'm only enforcing a zero boundary condition normal to the interior face, and then an applied boundary condition normal to the top surface. All of the other DOFs are free to move.

Now as far as mesh generation/refinement goes for the specific problem I'm looking at our mesh is generated using the following command:

mesh = new Mesh(toml_opt.nx, toml_opt.nx, toml_opt.nx, Element::HEXAHEDRON, 0, toml_opt.mx, toml_opt.mx, toml_opt.mx);

where the toml_opt.nx is just our inputted desired number of elements along a given axis.

Let me know if any of the above could be further clarified on for the description of our problem, and I'll do my best to either further expand or clarify on that point.

edit: I forgot to mention that it's also just a monotonic tension test out to 1% strain.

@rcarson3
Copy link
Owner Author

rcarson3 commented Apr 24, 2019

@tzanio It looks like the changes were introduced in the pre-okina tag. I'll probably need to take a look through the commit history to see if anything pops out to me that could be causing the slight differences.

You did mention that there were some changes related to the mesh refinement which I could see playing a role in this if some nodes have slightly different starting positions from the old mesh we're using. If that's the case I could see this being something that could perturb the solution just enough to cause it to start to diverge from the older code base's results.

edit: From looking at the mesh files it's hard to say whether or not there's any differences in the nodes, since the nodes that belong on each processor seem to have changed. However, I can see this contributing to some differences, since we are no longer performing reductions in the same order as previously.

@tzanio
Copy link
Collaborator

tzanio commented Apr 25, 2019

If I understand correctly, the differences between pre-okina and your current branch are due to the following PRs:

dd899e1 - (tag: pre-okina) Merge pull request mfem#843 from mfem/signed-char-fix (2 weeks ago)
eac34eb - Merge pull request mfem#824 from mfem/IdentityTranspose (2 weeks ago)
8734743 - Merge pull request mfem#825 from mfem/vis-keys-dev (2 weeks ago)
5b26939 - Merge pull request mfem#817 from mfem/refine-1d-mesh (3 weeks ago)
8d1ef21 - Merge pull request mfem#811 from mfem/periodic-mesh-bdr-transform-fix (3 weeks ago)
a8f0931 - Merge pull request mfem#697 from mfem/mesh-reordering-dev (3 weeks ago)
8bb83a0 - Merge pull request mfem#808 from mfem/bugfix/delete-faces-table (4 weeks ago)
00bae38 - Merge pull request mfem#816 from mfem/bugfix/memcheck (4 weeks ago)
5d29afc - Merge pull request mfem#752 from mfem/lor2ho-dev (4 weeks ago)
ea9aecc - Merge pull request mfem#748 from mfem/volta-point-charge-dev (5 weeks ago)
11c1fab - Merge pull request mfem#759 from mfem/artv3/const-DenseTensorData (8 weeks ago)
9984738 - Merge pull request mfem#728 from mfem/stefanozampini/fix-int64build (9 weeks ago)
402a348 - Merge pull request mfem#744 from mfem/amr-exchange-face-nbr-fix (9 weeks ago)
0ce4bb4 - Merge pull request mfem#724 from pghysels/master (10 weeks ago)
3e9a86c - Merge pull request mfem#681 from najlkin/pr5 (3 months ago)
da7b500 - Merge pull request mfem#693 from mfem/derefine-vector-spaces (3 months ago)
7cfb879 - Merge pull request mfem#635 from mfem/periodic-nurbs-v2-dev (3 months ago)

My guess is that the differences are due to mfem#697 or mfem#744. (You can check using the hashes above)

Either way, if pre-okina and the 4.0-rc tags show no difference between them, the GPU code should be safe to merge.

@rcarson3
Copy link
Owner Author

rcarson3 commented Apr 25, 2019

@tzanio It looks like it was due to mfem#697. I had to turn off the default setting to use the space-filling ordering in order to get back to the results I had previously.

edit: Also, I forgot to mention that we're working on a set of questions related to the Okina branch that we have that we'll be sending out to you and the others on the MFEM team in the near future.

The newer inline mesh generation introduced in the pre-okina tag of MFEM changed how elements were ordered according to a space-filling order. This option was made default in-order to satisfy some issues related to non-conforming meshes. It turns out this caused some diverging material responses in some of our standard monotonic tension tests out to 1% strain when using symmetric BCs. We therefore need to tell the inline mesh generator that we want to use the old lexicographic ordering.
@rcarson3 rcarson3 merged commit f8f48e1 into exaconstit-dev Apr 25, 2019
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.