iam having this issue how can is resolve this Undefined function or variable 'M'. Error in Untitled (line 39) MW = perform_curvelet_transform(M, options);
Show older comments
clear all; close all; clc; v = VideoReader('foreman.mp4'); tic numFrames = v.NumberOfFrames;
k=1; while k<=numFrames frame=read(v,k); frame=imresize(frame,[256 256]); frame=double(frame); [a b z]=size(frame);
frame = frame/255.0; sigma = .05; redChannel = frame(:, :, 1); greenChannel = frame(:, :, 2); blueChannel = frame(:, :, 3);
xr = redChannel + sigma*randn(size(redChannel)); xg = greenChannel + sigma*randn(size(greenChannel)); xb = blueChannel + sigma*randn(size(blueChannel));
noisyRGB = cat(3,xr,xg,xb);
MW = perform_curvelet_transform(M, options); hh =MW ; redMF = hdenoise(xr,hh); g greenMF = hdenoise(xg,hh); blueMF = hdenoise(xb,hh); rgbFixed = cat(3, redMF,greenMF,blueMF);
imshow([frame,noisyRGB,rgbFixed],[0,1]) k=k+1;
end toc
1 Comment
madhan ravi
on 6 Nov 2018
Upload your code
Answers (1)
madhan ravi
on 6 Nov 2018
0 votes
In the above code you didn’t mention the variable M which causes the error.
2 Comments
madhan ravi
on 6 Nov 2018
P.S - I have no experience in curvlet transformation
But all I am sure of is you haven’t defined M in your script but your using at the end which causes the error
Categories
Find more on Logical in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!