From: Steven_Lord on 4 Aug 2010 15:08 "Sofia Häggberg" <hd.int.assNOSPAM(a)gmail.com> wrote in message news:i3c78o$igm$1(a)fred.mathworks.com... > since I get: > ??? Out of memory. Type HELP MEMORY for your options. > > any help...? As others have said, this matrix is going to require a LARGE contiguous block of memory. numElements = 100000*3000; numBytes = numElements*8; numGB = numBytes/(1024^3) In order to create this matrix you need a contiguous block of over 2 GB worth of memory. Doing anything _with_ this matrix may require another block the same size, depending on what you're trying to do with it. Whether or not there's an alternative depends on what, SPECIFICALLY, you're trying to do with it. For example, storing this as a sparse matrix (HELP SPARSE) may help as long as whatever function you're trying to use on it supports sparse matrices. -- Steve Lord slord(a)mathworks.com comp.soft-sys.matlab (CSSM) FAQ: http://matlabwiki.mathworks.com/MATLAB_FAQ To contact Technical Support use the Contact Us link on http://www.mathworks.com
From: Stan Bischof on 4 Aug 2010 16:24 "Sofia Hagberg" <hd.int.assNOSPAM(a)gmail.com> wrote: > since I get: > ??? Out of memory. Type HELP MEMORY for your options. > > any help...? zeros(100000, 3000); it is completely possible. Just did it using R2010A. Howevr it takes the Matlab process size to 3.5GB since that is a large block of data. That means that unless you are running 64-bit code on a 64-bit OS you are going to not be able to proceed. I'd bet you are on 32-bits in which case the error message you are seeing is exactly correct- "out of memory" Stan PS - zeros(100000, 30000); also works- but of course it takes scads of RAM
First
|
Prev
|
Pages: 1 2 Prev: DISABLE NNTRAINTOOL WINDOW Next: Really need help to speed up piece of code |