|
Ublas : |
From: Gunter Winkler (guwi17_at_[hidden])
Date: 2006-06-13 17:22:59
Am Dienstag, 13. Juni 2006 03:08 schrieb Haroon Khan:
> Yes, I am! One of the reasons why I was looking into ublas is was the
> sparse matrix and vector classes. I'm dealing with matrices that are
> 352x240, but most of them have zero elements, and it just seemed to
> be a big waste of memory to have dense matrices.
I would not bother with sparsity for such small matrices (88k values fit
in most cpu's L2 caches) if it is just for saving memory. Using sparse
data means an additional level of indirection for each element access
and you lose the ability to apply SIMD instructions or other nice
optimizations for dense matrices. (You do image processing, don't you?)
I would suggest using banded matrices as a compromise if the bandwidth
of the matrix is small but known.
btw. What kind of algorithms do you think of? Maybe some already
implemented it.
mfg
Gunter