how to solve the imresize syntax error when the syntax is right as i have checked it ?

2 ビュー (過去 30 日間)
the error is given below
??? Error using ==> imresize>parsePreMethodArgs at 333 Invalid input syntax; input image missing from argument list.
Error in ==> imresize>parseInputs at 257 [params.A, params.map, params.scale, params.output_size] = ...
Error in ==> imresize at 141 params = parseInputs(varargin{:});
Error in ==> test1>pushbutton1_Callback at 102 k1=imresize(k,[300,300]);
Error in ==> gui_mainfcn at 96 feval(varargin{:});
Error in ==> test1 at 41 gui_mainfcn(gui_State, varargin{:});
Error in ==> @(hObject,eventdata)test1('pushbutton1_Callback',hObject,eventdata,guidata(hObject))
??? Error while evaluating uicontrol Callback
  2 件のコメント
Image Analyst
Image Analyst 2015 年 12 月 31 日
Put this on line 102, right before you call imresize()
whos k
What does it show in the command window. Is the badly-named k a 2-D gray scale array, or a 3-D true color RGB image?
Adnan Saify
Adnan Saify 2015 年 12 月 31 日
編集済み: Adnan Saify 2015 年 12 月 31 日
it is showing
Name Size Bytes Class Attributes
k 1x13 26 char
thanx for support

サインインしてコメントする。

採用された回答

Walter Roberson
Walter Roberson 2015 年 12 月 31 日
You have passed in the name of an image instead of passing in the image itself.
In your code you have
k=handles.pic;
p=handles.pic1;
Make that
k = imread(handles.pic);
p = imread(handles.pic1);
  1 件のコメント
Adnan Saify
Adnan Saify 2015 年 12 月 31 日
thanx a lot it helped a lot but i am not getting rid of following errors(attached updated file)
??? Reference to non-existent field 'result'.
Error in ==> test1>pushbutton1_Callback at 151 set(handles.result,'String',total_matched_percentage);
Error in ==> gui_mainfcn at 96 feval(varargin{:});
Error in ==> test1 at 41 gui_mainfcn(gui_State, varargin{:});
Error in ==> @(hObject,eventdata)test1('pushbutton1_Callback',hObject,eventdata,guidata(hObject))
??? Error while evaluating uicontrol Callback

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeMigrate GUIDE Apps についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by