Phase Shuffle takes a lot of memory, Is there any way to avoid this? Thanks.
조회 수: 1 (최근 30일)
이전 댓글 표시
function dlY=shuffle3d2(dlX)
num1=size(dlX,1);
num2=size(dlX,2);
num3=size(dlX,3);
k=randi([-2 2],1);
idy=1:num2;
idz=1:num3;
dlY=dlX;
if k>0
dlY(1:num1-k,idy,idz)=dlX(k+1:num1,idy,idz);
dlY(num1-k+1:num1,idy,idz)=dlX(num1-1:-1:num1-k,idy,idz);
elseif k<0
dlY(1:num1+k,idy,idz)=dlX(1:num1+k,idy,idz);
dlY(num1+k+1:num1,idy,idz)=dlX(1-k:-1:2,idy,idz);
else
end
댓글 수: 0
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Sequence and Numeric Feature Data Workflows에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!