ExtremeFLOW / neko

/ᐠ. 。.ᐟ\ᵐᵉᵒʷˎˊ˗
https://neko.cfd/
Other
159 stars 27 forks source link

1D stats - For when you have two homogenous directions #1328

Open MartinKarp opened 6 days ago

MartinKarp commented 6 days ago

Adds support for directly outputting averaged statistics into a 1D grid. Useful for things like channel flow where one has two homogenous directions.

Things to fix still: Documentation and comments in the code. Perhaps some clean up as well.

This PR still uses the old statistics layout, next up (at some point) is to update the stats to become a simcomp and perhaps scrap the split between first-order moments and all the others and add options to only get stats for the Reynolds stresses.

I had quite a bit of issues with this PR on the Cray compiler which did not like me adding the map_1d into the output classes. In particular, if one changes the volume_per_gll_lvl to a vector_t everything segfaults.

In addition, I had issues with GS_OP_MIN as we don't have support for it when using device mpi, I hacked my way around it, which was possible in this case, but not in general. Do we have any idea on how to solve it as the atomicMin operation in HIP only works for integers? It is not pressing, but would be nice to have support for it.

MartinKarp commented 2 days ago

Thats because the 1d fields writer needs to know the mass matrix for doing the proper averages.

MartinKarp commented 2 days ago

Perhaps the best is to close this PR and simply include it when I merge the simcomp statistics?