Parfor cannot serialize data which is too large

조회 수: 2 (최근 30일)
James
James 2013년 11월 6일
댓글: James 2013년 11월 7일
I have a parfor loop which calculates eigenvectors as a function of frequency, and stores all of them for post-processing. The size of the eigenvectors is 924*200 (Temp_zvAi for instance), and the size of zuxAi is 924*200*1311. The eigenvectors are complex, and zuxAi is around 3.8GB. Parfor returns the serialization error. How to get around this please? The code looks like below:
parfor fcount=1:Numsam
[Amat,Bmat]=functionof(fcount);
[Temp_zkA,Temp_zvAi]=eigenSolver (jn1,Amat,Bmat);
Temp_zuxAi=Temp_zvAi(1:nA,1:jn1);
zuxAi(:,:,fcount)=Temp_zuxAi;
Temp_zuyAi=Temp_zvAi(nA+1:2*nA,1:jn1);
zuyAi(:,:,fcount)=Temp_zuyAi;
Temp_zuzAi=Temp_zvAi(2*nA+1:3*nA,1:jn1);
zuzAi(:,:,fcount)=Temp_zuzAi;
end
  댓글 수: 2
Matt J
Matt J 2013년 11월 6일
편집: Matt J 2013년 11월 6일
Your code looks like an in complete example. In particular, none of the Temp_ quantities show any dependence on fcount. For all we can see, they can be pre-computed before the loop and all zu_xyz_Ai(:,:,fcount) will be copies of each other.
James
James 2013년 11월 6일
편집: James 2013년 11월 6일
Matt, thanks for your answer. The code only shows the places where errors are caught. Temp_ quantities depend on fcount, as Amat and Bmat are matrices dependant on fcount. The frequency dependence is irrelevant to the current problem so I deleted them.
I added one line to the code to clarify this.

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

채택된 답변

Edric Ellis
Edric Ellis 2013년 11월 7일
The limit on PARFOR data transfers was removed in R2013a. Please upgrade if you can.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Parallel for-Loops (parfor)에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by