fozziethebeat / S-Space

The S-Space repsitory, from the AIrhead-Research group
GNU General Public License v2.0
203 stars 106 forks source link

java.lang.IndexOutOfBoundsException #68

Open jerrygaoLondon opened 9 years ago

jerrygaoLondon commented 9 years ago

Hi,

I got IndexOutOfBoundsException when attempting to compute SVD for a large matrix (3404 x 21951). The matrix is created using edu.ucla.sspace.matrix.SparseOnDiskMatrix. The numDimensions is set to maximum size (21951) of matrix so that i can get the diagonal matrix S for the large matrix. It runs OK for small matrix. Any idea about why this exception happens ? thanks, Jerry

Exception in thread "main" java.lang.IndexOutOfBoundsException: 8268500 at java.nio.DirectDoubleBufferS.get(DirectDoubleBufferS.java:253) at edu.ucla.sspace.matrix.OnDiskMatrix.get(OnDiskMatrix.java:161) at edu.ucla.sspace.matrix.factorization.SingularValueDecompositionMatlab.factorize(SingularValueDecompositionMatlab.java:141) at edu.ucla.sspace.matrix.factorization.SingularValueDecompositionMatlab.factorize(SingularValueDecompositionMatlab.java:63) ...

jerrygaoLondon commented 9 years ago

It turns out that it might be similar to the issue #58 . I'm trying to get S matrix for the large matrix, however, the SVDLIBC only return dimensions less than the number of rows.

Not sure why. I thing the data matrix for SVDLIBC should be "columns: variables/features, rows: data point".

Anyone can help to confirm this ?