parthenon-hpc-lab / parthenon

Parthenon AMR infrastructure
https://parthenon-hpc-lab.github.io/parthenon/
Other
109 stars 33 forks source link

Low-resolution outputs? #1001

Open bprather opened 7 months ago

bprather commented 7 months ago

I know Parthenon now supports histograms, & therefore with some fudging, 2D slices. But what about downsampling?

It would be useful in KHARMA to be able to output a 1:2 or 1:4 resolution dump at a much higher cadence, in order to capture fast overall features without eating all our scratch space -- at best, perhaps this means interpolation onto a single grid, or a whole different SMR layout. We can do this in post, of course, but that limits how far we can even run before pruning back all the high-res cruft, and I imagine the pruning step will be very time-intensive.

If this is a desirable feature for more downstreams, I can try to work on it at the Parthenon level, so I'm opening it here. Mostly I'm worried linear interpolation may not be what the user wants for all variables. Maybe some repeated call to the restriction operator? Maybe interpolate onto a whole new mesh with a linear or user-chosen function?

Yurlungur commented 7 months ago

This is a cool idea, and I would be interested in this capability. Maybe limit to only vars that can be restricted? And just restrict into the coarse buffer?

BenWibking commented 7 months ago

I think this would be very interesting for several AthenaPK applications as well 👍

bprather commented 7 months ago

Cool, I figured it might be useful. Using the coarse buffers is a good idea, I bet I can whip up the easy 1:2 version in a few weeks here when I get a chance, and we can talk any more advanced features on the PR.

pgrete commented 7 months ago

Yes, this would definitely be useful. In fact, we already talked about this on our downstream side and I put some thought around this in the context of OpenPMD outputs. I think this can be realized in few 10s LOC so I'll try to add it along the go.