Registered Member
|
In my application I am doing a lot of matrix multiplications - roughly (256x1500)x(1500x2000).
The second matrix is about 85% zeros. I tried using sparse matrix for the second matrix, but it became about 2x as slow. For this level of sparsity, is dense matrix still the way to go? The zeros are more or less evenly distributed. Memory is not a problem. Thanks! |
Moderator
|
I'm not really surprised: dense matrix products fully exploits CPU's power, whereas a sparse representation involves a significant overhead, so 85% of zeros is not sparse enough!
|
Registered Member
|
Ah! That makes sense. Thanks.
Back to dense matrices for me! |
Registered users: Bing [Bot], Google [Bot], Yahoo [Bot]