Take a look at the rows in the rows dot product call to see if there’s any redundancy there. If so, see here on computing on just the unique rows then indexing into the result.
Related topics
| Topic | Replies | Views | Activity | |
|---|---|---|---|---|
| Speed of matrix multiplication versus multiplication loops | 4 | 1835 | November 8, 2022 | |
| Improving the efficiency of *_dot_product for trinary-and-redundant matrices | 38 | 1585 | May 3, 2023 | |
| Looking for suggetions to make codes more efficient | 4 | 249 | April 28, 2024 | |
| Elementwise multiplications with row sums appear to be slow | 32 | 1548 | August 23, 2021 | |
| How to vectorize this code? | 3 | 523 | September 3, 2020 |