Working With Very Large Array

조회 수: 5 (최근 30일)
Heather Procter
Heather Procter 2015년 11월 13일
댓글: Walter Roberson 2015년 11월 13일
For my work I need to create and work with very large arrays of data (on the order of 1,000*400,000) to simulate many simultaneous random walks. I was wondering what would be the best way to go about this, as I run out of memory before I even get close to creating an array of that size.
Obviously I'll need to write it to the disk in some way. I essentially need to create the array one row at a time, creating the next row from the previous one.
  댓글 수: 1
Walter Roberson
Walter Roberson 2015년 11월 13일
Those arrays are not quite 4 gigabytes each, even if you use double precision (which might not be necessary for your purpose.) Make sure you use a 64 bit MATLAB and at least 2 gigabytes of RAM plus 4 gigabytes per array of that size that needs to exist simultaneously.

댓글을 달려면 로그인하십시오.

채택된 답변

Adam
Adam 2015년 11월 13일
Try looking into using a matfile
doc matfile
It allows you to work with a large data set from file rather than from memory. Access is slower, of course, but not massively so, especially for the first index of the array. It gets slower for accessing subsequent dimensions (or at least it did last time I tested it which was a little while ago).

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Logical에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by