Error in the brain tumor detection code

조회 수: 8 (최근 30일)
Susheela B
Susheela B 2021년 6월 22일
댓글: Walter Roberson 2021년 6월 22일
I am doing project on brain tumor detection classification.I run the code from the math work.I am getting about svmtrain and svmclassify and I changed the syntax of that but still I am getting errors.
ERROR:
Name Size Bytes Class Attributes
DWT_feat 31x124 30752 double
Name Size Bytes Class Attributes
G 124x30 29760 double
Error using classreg.learning.FitTemplate/fillIfNeeded (line 666)
kernel_function is not a valid parameter name.
Error in classreg.learning.FitTemplate.make (line 125)
temp = fillIfNeeded(temp,type);
Error in ClassificationSVM.template (line 235)
temp = classreg.learning.FitTemplate.make('SVM','type','classification',varargin{:});
Error in ClassificationSVM.fit (line 239)
temp = ClassificationSVM.template(varargin{:});
Error in fitcsvm (line 343)
obj = ClassificationSVM.fit(X,Y,RemainingArgs{:});
Error in BrainMRI_GUI>pushbutton2_Callback (line 181)
svmStruct1 = fitcsvm(xdata,group,'kernel_function', 'linear');
Error in gui_mainfcn (line 95)
feval(varargin{:});
Error in BrainMRI_GUI (line 46)
gui_mainfcn(gui_State, varargin{:});
Error in
matlab.graphics.internal.figfile.FigFile/read>@(hObject,eventdata)BrainMRI_GUI('pushbutton2_Callback',hObject,eventdata,guidata(hObject))
Error while evaluating UIControl Callback.
code file is also attached

채택된 답변

Walter Roberson
Walter Roberson 2021년 6월 22일
the parameter name is 'KernelFunction'
If this helps you then please go over to his Answer and vote for it, as he is the person who found the solution and wrote it up.
  댓글 수: 2
Susheela B
Susheela B 2021년 6월 22일
But still error exists.
Error:
Name Size Bytes Class Attributes
DWT_feat 31x124 30752 double
Name Size Bytes Class Attributes
G 124x30 29760 double
Error using ClassificationSVM (line 249)
Use fitcsvm to train an SVM model.
Error in BrainMRI_GUI>pushbutton2_Callback (line 182)
species = ClassificationSVM(svmStruct1,feat,'showplot',true);
Error in gui_mainfcn (line 95)
feval(varargin{:});
Error in BrainMRI_GUI (line 46)
gui_mainfcn(gui_State, varargin{:});
Error in
matlab.graphics.internal.figfile.FigFile/read>@(hObject,eventdata)BrainMRI_GUI('pushbutton2_Callback',hObject,eventdata,guidata(hObject))
Error while evaluating UIControl Callback.
the files are attached

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 MATLAB에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by