-
-
Notifications
You must be signed in to change notification settings - Fork 990
feat: add blas/ext/base/drss
#8722
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
base: develop
Are you sure you want to change the base?
feat: add blas/ext/base/drss
#8722
Conversation
---
type: pre_commit_static_analysis_report
description: Results of running static analysis checks when committing changes.
report:
- task: lint_filenames
status: passed
- task: lint_editorconfig
status: passed
- task: lint_markdown
status: passed
- task: lint_package_json
status: passed
- task: lint_repl_help
status: passed
- task: lint_javascript_src
status: passed
- task: lint_javascript_cli
status: na
- task: lint_javascript_examples
status: passed
- task: lint_javascript_tests
status: passed
- task: lint_javascript_benchmarks
status: passed
- task: lint_python
status: na
- task: lint_r
status: na
- task: lint_c_src
status: missing_dependencies
- task: lint_c_examples
status: missing_dependencies
- task: lint_c_benchmarks
status: missing_dependencies
- task: lint_c_tests_fixtures
status: na
- task: lint_shell
status: na
- task: lint_typescript_declarations
status: passed
- task: lint_typescript_tests
status: passed
- task: lint_license_headers
status: passed
---
Coverage Report
The above coverage report was generated for the changes in this PR. |
| scl = 1.0; | ||
| sumsq = amed; | ||
| } | ||
| return sumsq * ( scl * scl ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@nakul-krishnakumar I am not sure this behaves quite as you expect. The implementation that you should be following is not exactly what we did for drrss, as that has different scaling properties. Instead, you should be following
- https://www.netlib.org/lapack/explore-html/d8/d76/group__lassq_gae8f40b0a34771b4f2d9c863de3af7be5.html#gae8f40b0a34771b4f2d9c863de3af7be5
- https://github.com/stdlib-js/stdlib/tree/develop/lib/node_modules/%40stdlib/lapack/base/dlassq
Notice that the underlying algorithm is similar, but not the same, and certainly not the same as simply undoing sqrt operations.
I suggest implementing the algorithm in dlassq and instead of returning a scale and a sum, doing what you do here and returning scale**2 * sumsq.
Additionally, as previously discussed, we'll also want different variants of drss based on the underlying summation algorithm (e.g., drsskbn, drsskbn2, drssli, drsslipw, drssors, drsspn, drsspw). As such, I recommend renaming this package to drssbl as this is based on Blue's algorithm for computing the Euclidean norm of a vector.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the review @kgryte.
Also does the renaming apply for drrss (square root of residual sum of squares) too? Current implementation of drrss depends on Blue's algorithm, so can it too have the different variants you mentioned above?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can deal with that later. For now, fine to leave as is, as we can use a different migration strategy for that package given that it has already been created.
type: pre_commit_static_analysis_report
description: Results of running static analysis checks when committing changes. report:
Resolves None.
Description
This pull request:
blas/ext/base/drss.Related Issues
This pull request has the following related issues:
Questions
No.
Other
No.
Checklist
AI Assistance
If you answered "yes" above, how did you use AI assistance?
Disclosure
None.
@stdlib-js/reviewers