Error in code, "Invalid expression. Check for missing multiplication operator, missing or unbalanced delimiters, or other syntax error. To construct matrices, use brackets instead of parentheses. "

function
RWA_Transform('Image_30x1528x60_u16.raw',30,1528,60,'uint16','output/RWA.raw')
fid=fopen('Image_30x1528x60_u16.raw','r');
G=fread(fid,1528*60*30,'uint16',0,'b');
im = reshape(G,60*1528,30);
l = ceil(log2(30));
[RWAim W] = RWA(im,l,1);
fid=fopen(output,'w');
fwrite(fid,RWAim,'int16',0,'b');
sifile = [output '_SI.mat'];
save(sifile,'W');
fprintf('\n Image: %s \n size: (%u, %u, %u) \n Transformed: %s \n side information: %s \n','Image_30x1528x60_u16.raw',30,1528,60,'output/RWA.raw',sifile);

댓글 수: 7

[RWAim W] = RWA(im,l,1);
Showing the above error in this line.
Thank you for the reply, error is still there.
Can you show the complete error message? All the red text.
I did some modification as shown below:
function RWA_Transform(raw_image,z,y,x,dtype,output)
fid=fopen('Image_30x1528x60_u16.raw','r');
G=fread(fid,1528*60*30,'uint16',0,'b');
im = reshape(G,60*1528,30);
l = ceil(log2(30));
[RWAim, W] = RWA(im,l,1);
fid=fopen('Image_30x1528x60_u16.raw','w');
fwrite(fid,RWAim,'int16',0,'b');
sifile = ['output' '_SI.mat'];
save(sifile,'W');
fprintf('\n Image: %s \n size: (%u, %u, %u) \n Transformed: %s \n side information: %s \n','Image_30x1528x60_u16.raw',30,1528,60,'output/RWA.raw',sifile);
Getting the output as :
>> RWA_Transform
Image: Image_30x1528x60_u16.raw
size: (30, 1528, 60)
Transformed: output/RWA.raw
side information: output_SI.mat
KUNDAN, this does not show the error message. The question title mentions a different message. Is it not happening now?

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

답변 (0개)

카테고리

도움말 센터File Exchange에서 Function Handles에 대해 자세히 알아보기

질문:

2020년 5월 6일

댓글:

2020년 5월 6일

Community Treasure Hunt

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

Start Hunting!

Translated by