Conversation
Owner
Author
|
Im not sure how to move forward from here. I cant tell if you blur kernel is working properly |
added 3 commits
November 5, 2022 02:04
stevenireeves
requested changes
Nov 7, 2022
Comment on lines
+127
to
+134
| for(int i =0; i < CL2.width; i++) | ||
| { | ||
| for(int j =0; j<CL2.height; j++) | ||
| { | ||
| sum+= CL2.elements[i*CL2.width+j]; | ||
| } | ||
| } | ||
| std::cout << "Serial Sum: " << sqrt(sum) <<std::endl; |
Collaborator
There was a problem hiding this comment.
Do you really want to commit the serial part?
stevenireeves
requested changes
Nov 7, 2022
Owner
Author
|
The parallel L2 norm im getting is slightly different from the serial version |
stevenireeves
requested changes
Nov 7, 2022
stevenireeves
requested changes
Nov 8, 2022
stevenireeves
requested changes
Nov 12, 2022
Comment on lines
+136
to
+137
| reduce<<<dimGridReduce,dimBlockReduce,1024*sizeof(float)>>>(reduced,L2); | ||
| reduce<<<1,dimBlockReduce,1024*sizeof(float)>>>(reduced,reduced); |
Collaborator
There was a problem hiding this comment.
We'll need more stages of reduce here. width*height > 1024^2. In fact, the image is 1199x1200 I'm also not seeing a sqrt here.
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.
Am I on the right track? So far I think my next step is to implement the cimg library and do the math on each individual color values.