Struct contents reference from a non-struct array object.
8 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
I am writting a code and in the last line of the code it shows the error "Struct contents reference from a non-struct array object.". Here is my code:
fic='cam2_person015.png';
img=imread(fic);
ti=size(img);
figure(1)
imshow(img);
normImage = mat2gray(img);
figure; imshow(normImage);
[x,y] = find(img);
lambda = 10.^(-9);
% lambda = eig(shadow);
meu = 10.^6;
H = heaviside(-y);
e = 1;
ee = e.^-((sqrt(x)/2.*sqrt(lambda))+(sqrt(y)/2.*sqrt(meu)));
anisotrophic_filter = img.*normImage.H.x.ee;
Kinldy check this. I shall be very thankful for the kind act of consideration.
6 Kommentare
Jan
am 22 Mär. 2019
@Shah Bano: Then use the debugger to check the sizes of the array. We cannot guess this detail.
By the way, 10.^(-9) is an expensive power operation, while 1e-9 is a cheap constant. The runtime will not matter here, but it is a good programming practice.
Antworten (0)
Siehe auch
Kategorien
Mehr zu Image Preview and Device Configuration finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!