This project has moved. For the latest updates, please go here.


SVD and L2Norm out of memory exception



I am working on image procession project and using SVD and L2norm on DenseMatrix. The matrix consists of of 40000 rows and 20 columns. It consists of 20 images of resolution 200200 stacked as matrix columns.
For testing, when I scale the images to be 150
150 and below the SVD works correctly.

Working in VS 2010 professional, win7 , 64bit.
Closed Oct 3, 2013 at 12:18 AM by cdrnet
Tracked at GitHub


EvgeniyKushnir wrote Dec 15, 2012 at 7:22 AM

The code sample i use:

this.D = new DenseMatrix(rows, cols,0);
       for(int i=0; i<rows; i++)
            for (int j = 0; j < cols; j++)
                this.D[i,j] =Matrix_D[i, j]; // Matrix_D is byte[,]

         float mu_k = this.D.L2Norm(); 
         var svd = D.Svd(true);
         MessageBox.Show("SVD OK");
when the Matrix_D size is 180003 I get "out of memory exception"
when the Matrix_D size is 15000
3 everything is ok.

cdrnet wrote Oct 3, 2013 at 12:18 AM