Skip to content
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

Implement and test a CUDA version of the module map #154

Closed

Conversation

stephenswat
Copy link
Member

The module map was originally designed to be GPU friendly, and we now reap the fruits of that decision. This implementation of a CUDA version of that code is quite short and simple to understand. This pull request adds an owning CUDA version of the module map, as well as a light-weight non-owning view object which is designed to be passed to kernels. It also tests the class.

This pull request depends on #153.

@stephenswat stephenswat added feature New feature or request cuda Changes related to CUDA labels Mar 28, 2022
@stephenswat
Copy link
Member Author

This PR also depends on acts-project/vecmem#172.

@stephenswat stephenswat force-pushed the feat/cuda_module_map branch from 0ad5be2 to 5af1ef0 Compare April 12, 2022 15:59
@stephenswat stephenswat marked this pull request as ready for review April 12, 2022 16:00
@stephenswat
Copy link
Member Author

This is now ready to be merged.

The module map was originally designed to be GPU friendly, and we now
reap the fruits of that decision. This implementation of a CUDA version
of that code is quite short and simple to understand. This commit adds
an owning CUDA version of the module map, as well as a light-weight
non-owning view object which is designed to be passed to kernels.
@stephenswat stephenswat force-pushed the feat/cuda_module_map branch from 5af1ef0 to 9d35141 Compare April 12, 2022 16:21
Copy link
Contributor

@beomki-yeo beomki-yeo left a comment

Choose a reason for hiding this comment

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

Just very trivial comments...

This test is rather simple, but effective. It loads a CPU module map
from an input file, constructs a CUDA module map and then - for each
module - launches a kernel which retrieves the relevant transformation
matrix and sends it back to the CPU. The CPU will then check whether
these transformation matrices retrieved from the GPU are correct.
@stephenswat stephenswat force-pushed the feat/cuda_module_map branch from 9d35141 to 1cbed80 Compare April 13, 2022 17:33
@stephenswat
Copy link
Member Author

Thanks! You have a keen eye for this! 😄

@stephenswat
Copy link
Member Author

Closing this as there seems to be little interest in it.

@beomki-yeo
Copy link
Contributor

Actually I need it for GPU.
I was not event aware of that this PR has existed so I made a (very simple) module map for CKF study recently.
So I guess it is worth keeping this alive

@stephenswat
Copy link
Member Author

Mind you this is a map from module identifiers to transformation matrices, although we can easily repurpose this for spacepoint identifier to module identifier mappings, which I guess is what you need for the CKF.

@stephenswat stephenswat reopened this Mar 17, 2023
@beomki-yeo
Copy link
Contributor

although we can easily repurpose this for spacepoint identifier to module identifier mappings,

Exactly. I hope we can generalize it for multiple purposes.

@stephenswat
Copy link
Member Author

This should no longer be necessary.

@krasznaa
Copy link
Member

Right now you could still argue that we don't have the correct thing in place yet. But as I wrote in #592 (comment), I'll have some EDM updates in the foreseeable future, which will absolutely replace this PR.

So yeah, I agree with closing it. Even if I was only going to suggest it a little later, once I pushed my EDM changes through. 😉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cuda Changes related to CUDA feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants