Error in .exe but not in .m
Mostra commenti meno recenti
Hello,
I've generated an executable file from an matlab script using the deploytool of Matlab (type: Console application).
When I run the code in Matlab there are no errors. However, when I run the .exe file, with the same inputs, from cmd I got an error: "Matrix dimensions must agree". Below I show you the code which generated the error:
Vignetting(Vignetting<=threshold)=0;
I have tried to replace this line by:
idx=find(Vignetting<=threshold);
Vignetting(idx)=0;
But once again, I got the error "Matrix dimensions must agree" when I run the .exe
Why do I get this error in the .exe file and in Matlab the code works well? How can I solve this problem (recommendations)?
Thank you very much in advance,
Risposta accettata
Più risposte (2)
Image Analyst
il 15 Set 2016
Put these lines before that line
whos Vignetting
whos threshold
What does it show you? Is threshold a scalar or an double array, or a string? How did you set threshold?
Helder Correia
il 16 Set 2016
Categorie
Scopri di più su Application Deployment in Centro assistenza e File Exchange
Prodotti
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!