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

Adding Support for arbitrary point distributions on the sphere, as from DSE paper #56

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

LeviLingsch
Copy link

I have added several files and functions.

examples/train_fno_dse.py provides the option to load two different models and train them via two slightly different functions. The models are SFNODSEFp and SFNODSEVp (SFNO using Discrete Spectral Evaluations with Fixed/Variable Points). "Fixed points" means sampling locations are fixed across all training data, while "Variable points" means that the sampling locations are different between the samples.

The spherical harmonics transformed is performed by the class RealSHTDSE for fixed points and BatchedRealSHTDSE for variable points. These are both found in torch_harmonics/sht_dse.py. These classes must be initialized with the set of points and number of degrees for the SHT. They contain functions to perform both the forward and backward transform. The backward transform is not an inverse. Actually, the backward transform will return a field with values that differ from the original field by some constant. This can be by about an order of magnitude. For the purposes of operator learning, this was actually not an issue, since some scaling of the SHT coefficients is learned. I never bothered to fix this, but if someone is hoping to use this package strictly for "inverse" SHT on an arbitrary point distribution, this might not work for them.

The models for the SFNO on arbitrary points are found in examples/sfno_dse/models.

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.

1 participant