Hess tri structure gpu implementation#31
Merged
CalebDerrickson merged 3 commits intomasterfrom Feb 24, 2025
Merged
Conversation
amontoison
reviewed
Feb 24, 2025
| backend = KA.get_backend(hrows) | ||
| kernel = vecchia_generate_hess_tri_structure_kernel!(backend) | ||
|
|
||
| f(x) = (x * (x+1)) ÷ 2 |
Member
There was a problem hiding this comment.
Ok you use this function after but you could directly do it in the kernel.
It's what I do there:
https://github.com/exanauts/VecchiaMLE.jl/blob/master/src/VecchiaMLE_kernels.jl#L90-L93
amontoison
reviewed
Feb 24, 2025
Comment on lines
+18
to
+19
| #include("test_cpu_diagnostics.jl") | ||
| #include("test_memory_allocation_outliers_cpu.jl") |
Collaborator
Author
There was a problem hiding this comment.
I was using the test VecchiaMLE to check my kernel. Forgot to uncomment them. oops!
amontoison
reviewed
Feb 24, 2025
Comment on lines
+152
to
+156
| carry_offsets = CUDA.ones(Int, n) | ||
| view(carry_offsets, 2:n) .+= cumsum(f.(view(colptr_diff, 1:n-1))) | ||
|
|
||
| idx_offsets = CUDA.ones(Int, n) | ||
| view(idx_offsets, 2:n) .+= cumsum(view(colptr_diff, 1:n-1)) |
Member
There was a problem hiding this comment.
We don't want to add new allocations :)
amontoison
reviewed
Feb 24, 2025
Comment on lines
+211
to
+213
| println("CPU:\n") | ||
| println(hrows) | ||
| println(hcols) |
Member
There was a problem hiding this comment.
@CalebDerrickson You can't keep these debug printing when you merge your modifcations into the main branch.
Member
|
@michel2323 Can you review the PRs of @CalebDerrickson during this week? |
Member
|
Off-topic: They rebooted |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
First verison of kernel implementation. There might be a way to flatten the kernel more, allowing for more parallelization, but this should be fine for the moment.