Skip to content

Feature/wjiang/sphere pert - #187

Draft
weiyuan-jiang wants to merge 13 commits into
developfrom
feature/wjiang/sphere_pert
Draft

Feature/wjiang/sphere pert#187
weiyuan-jiang wants to merge 13 commits into
developfrom
feature/wjiang/sphere_pert

Conversation

@weiyuan-jiang

Copy link
Copy Markdown
Contributor

No description provided.

Weiyuan Jiang added 4 commits July 30, 2026 12:35
@weiyuan-jiang

Copy link
Copy Markdown
Contributor Author
compare_pert_xcorr2 compare_pert_xcorr10

@weiyuan-jiang

Copy link
Copy Markdown
Contributor Author

Sphere Perturbation Performance Results

  • Benchmark grid: 720 longitude by 360 latitude points (0.5 degree)
  • MPI ranks: 40

Measurements

xcorr/ycorr Filter order Sphere filter build Sphere field draw
2 degrees Mord=1 7.6359 s 0.2725 s
10 degrees Mord=2 0.0624 s 0.2566 s

Both generated sphere fields had zero mean to displayed precision and unit
standard deviation. The 2-degree field had range -3.89724 to 4.21915; the
10-degree field had range -3.05700 to 3.23377.

Realization Figure Runs

The realization figures were generated with four MPI ranks using the same
720 by 360 grid. These are the timings from the runs that produced
compare_pert_xcorr2.png and compare_pert_xcorr10.png.

xcorr/ycorr Rectangle build Rectangle draw Sphere build Sphere draw
2 degrees 0.0206 s 0.0251 s 12.1048 s 0.2158 s
10 degrees 0.0313 s 0.0277 s 0.0201 s 0.0645 s

Optimization

xcorr=2 switches to the stable Mord=1 direct-Legendre covariance path.
The current implementation distributes m-mode covariance and Cholesky work
across node-local MPI ranks and stores factors in shared memory. Previous
40-rank measurements for the non-distributed full-covariance path were about
119 seconds to build; the current 40-rank build is about 7.6 seconds.

@weiyuan-jiang

Copy link
Copy Markdown
Contributor Author

=== pert_statistics: recovered xcorr from generated fields ===
grid=720x360, MPI ranks=4
samples per rank=64
rectangle_random_fields: target= 2.00 deg, samples=256,
recovered xcorr= 1.984 deg (error= -0.016 deg)
build_sphere_filter: |Im(root)|= 911.7 > threshold; using direct Legendre covariance (Mord=1, stable)
sphere_random_fields: target= 2.00 deg, samples=256,
recovered xcorr= 1.989 deg (error= -0.011 deg)
rectangle_random_fields: target= 10.00 deg, samples=256,
recovered xcorr= 9.728 deg (error= -0.272 deg)
sphere_random_fields: target= 10.00 deg, samples=256,
recovered xcorr= 10.800 deg (error= 0.800 deg)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants