-
Notifications
You must be signed in to change notification settings - Fork 6
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
Matmul backup #6
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportBase: 99.27% // Head: 99.30% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## main #6 +/- ##
==========================================
+ Coverage 99.27% 99.30% +0.02%
==========================================
Files 12 12
Lines 690 716 +26
==========================================
+ Hits 685 711 +26
Misses 5 5
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
Seems like there are a lot of allocs. Can you do it more in-place somehow? |
A vast majority of allocations occur when generating new beliefs and storing these beliefs in the tree. While this could be improved by either preallocating beliefs at the very beginning or using something like a bump allocator around the belief updater, I'm not entirely sure it's worth the effort. Currently, allocations have an extremely negligible effect on performance. In profiles, elementary non-allocating array operations like As far as I can tell, the best ways of improving performance currently would be through #2, #3, and #7. That being said, the current implementation is already quite fast, so these improvements aren't absolutely necessary. |
What Matrix sizes are you evaluating on? It matters more once you have greater than 50x50 dimensions in your matrix. |
|
If I understand the code correctly |
Right, the line you're referencing is for initially populating the linear mapping matrix ( Lines 14 to 19 in 6baf19a
. |
Reduce alpha vector backup to a single matrix multiplication.
Current performance is quite bad relative to main branch, but I think the idea may still be worth pursuing.
Before
Tiger
Rocksample(5,5)
Rocksample(10,10)
After
Tiger
Rocksample(5,5)
Rocksample(10,10)