Skip to content

Add single-rank lsq pseudoinv factory test#1099

Merged
msimberg merged 22 commits intoC2SM:mainfrom
msimberg:lsq-pseudoinv-factory-test
Mar 17, 2026
Merged

Add single-rank lsq pseudoinv factory test#1099
msimberg merged 22 commits intoC2SM:mainfrom
msimberg:lsq-pseudoinv-factory-test

Conversation

@msimberg
Copy link
Contributor

@msimberg msimberg commented Mar 9, 2026

Related to #1065 (comment). This uses @nfarabullini's fixes for doing the LSQ_PSEUDOINV computation with a GPU backend from #1012 to have them merged separately.

This also adds LSQ_PSEUDOINV to the parallel test in test_parallel_grid_manager.py. This required changing the computation to avoid doing the SVD on halo points.

Custom dimensions are added for LSQ_PSEUDOINV to correctly declare the dimensions in the factory. Previously the dimension was equivalne to a scalar, which lead to the factory returning the plain numpy array. With this change the mypy type ignores can be removed from test_parallel_interpolation.py.

@msimberg
Copy link
Contributor Author

msimberg commented Mar 9, 2026

cscs-ci run default

@msimberg msimberg force-pushed the lsq-pseudoinv-factory-test branch from e71006f to 0c2ec7d Compare March 10, 2026 10:10
@msimberg
Copy link
Contributor Author

cscs-ci run default

@msimberg
Copy link
Contributor Author

cscs-ci run default

@msimberg msimberg requested a review from nfarabullini March 10, 2026 14:58
@msimberg
Copy link
Contributor Author

cscs-ci run default

@msimberg
Copy link
Contributor Author

cscs-ci run default

@msimberg
Copy link
Contributor Author

cscs-ci run default

@msimberg
Copy link
Contributor Author

cscs-ci run distributed

@msimberg
Copy link
Contributor Author

cscs-ci run default

@msimberg
Copy link
Contributor Author

cscs-ci run distributed

@msimberg msimberg marked this pull request as ready for review March 17, 2026 10:01
@msimberg msimberg requested a review from nfarabullini March 17, 2026 10:01
Copy link
Contributor

@nfarabullini nfarabullini left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Small edits here and there

Comment on lines 39 to 40
TODO:
replace this with a suitable library call
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we still need this TODO?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suspect it's still as valid as before (this PR doesn't change the validity).

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

but do we need it at all? I'm just confused of what kinf of library call should be used here instead of this function

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a fair question though I'll leave that consideration out of this PR.

It looks like @ajocksch added this functionality and the TODO, maybe you can comment if you think the TODO is still useful? If not, we can remove it separately.

@msimberg msimberg requested a review from nfarabullini March 17, 2026 13:51
@nfarabullini
Copy link
Contributor

cscs-ci run default

@nfarabullini
Copy link
Contributor

cscs-ci run distributed

@github-actions
Copy link

Mandatory Tests

Please make sure you run these tests via comment before you merge!

  • cscs-ci run default
  • cscs-ci run distributed

Optional Tests

To run benchmarks you can use:

  • cscs-ci run benchmark-bencher

To run tests and benchmarks with the DaCe backend you can use:

  • cscs-ci run dace

To run test levels ignored by the default test suite (mostly simple datatest for static fields computations) you can use:

  • cscs-ci run extra

For more detailed information please look at CI in the EXCLAIM universe.

@msimberg msimberg merged commit b3d024f into C2SM:main Mar 17, 2026
54 checks passed
@msimberg msimberg deleted the lsq-pseudoinv-factory-test branch March 17, 2026 16:43
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.

2 participants