-
Notifications
You must be signed in to change notification settings - Fork 55
CUDA: add basic complex number operation tests\n\nAdds kernel-based t… #730
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: main
Are you sure you want to change the base?
CUDA: add basic complex number operation tests\n\nAdds kernel-based t… #730
Conversation
…ests for device-side complex64 addition, multiplication, and absolute value. Skips under cudasim. NumPy is used as the reference. Scope is intentionally limited to safe, well-defined CUDA operations.
Greptile SummaryAdds three kernel-based tests for device-side Key changes:
The implementation is clean, follows existing test patterns in the codebase, and addresses issue #515 by expanding CUDA test coverage for complex number operations. Confidence Score: 5/5
Important Files Changed
|
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.
1 file reviewed, 2 comments
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
….py\n\n- Merged device-side complex64 operation tests (add, multiply, abs) into cudapy/test_complex.py as TestCudaComplexBasicOps for organizational consistency\n- Removed standalone test_complex.py file
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.
Additional Comments (1)
-
numba_cuda/numba/cuda/tests/cudapy/test_complex.py, line 62-66 (link)syntax: duplicate
numpyimport - already imported on line 2 asnp
1 file reviewed, 2 comments
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
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.
1 file reviewed, 1 comment
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
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.
1 file reviewed, 1 comment
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
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.
1 file reviewed, 1 comment
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
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.
1 file reviewed, 2 comments
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
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.
1 file reviewed, 2 comments
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
… duplicate numpy import and comment marker\n\n- Ensures no NameError at import time and code style is clean
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.
1 file reviewed, 3 comments
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
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.
Additional Comments (1)
-
numba_cuda/numba/cuda/tests/cudapy/test_complex.py, line 102-141 (link)style: duplicate imports - these imports are redundant since they're already present in lines 5-44 (after fixing the decorator on line 4)
1 file reviewed, 4 comments
…nd all imports come first\n- Removed duplicate imports\n- Kernels and TestCudaComplexBasicOps class now at end of file\n- Resolves NameError issues
This PR adds kernel-based tests for device-side complex64 operations: addition, multiplication, and absolute value.
Skips under cudasim due to divergent semantics
Uses NumPy as the reference oracle
Scope is intentionally limited to safe, well-defined CUDA operations (no division, power, or mixed-type ops)
This PR is intentionally narrow and reviewer-friendly, following the same discipline as previous CUDA test PRs.
#515