Another error in this context arises if my loading function gets more complex. I've implemented some own classifiers (as well with a predict method).
Loading the self-developed classes works but when I try to load the classifiers from the toolbox I get the error on the bottom.
The compiled and called function is:
function label=matlab_classifier_predict(file_name,data)
if contains(file_name,"PKK-Line")
%load user_written class PKK
classifier_obj= PKK.load(file_name);
elseif contains(file_name,"PKK-Ellipse")
%load user_written class PKK_ellipse
classifier_obj=PKK_ellipse.load(file_name);
else
%load matlab classifiers
load(file_name);
label=predict(classifier,data);
return
end
label=predict(classifier_obj,data);
end
An error occurred when evaluating the result from a function. Details: File C:\Program Files\MATLAB\MATLAB Runtime\v99\mcr\toolbox\stats\classreg\+classreg\+learning\+internal\makeClassificationModelAdapter.m, line 3, in @(x)istall(x) File C:\Program Files\MATLAB\MATLAB Runtime\v99\mcr\toolbox\stats\classreg\+classreg\+learning\+internal\makeClassificationModelAdapter.m, line 3, in makeClassificationModelAdapter File C:\Program Files\MATLAB\MATLAB Runtime\v99\mcr\toolbox\stats\classreg\ClassificationKNN.m, line 689, in ClassificationKNN.predict File C:\Users\steenbuck\AppData\Local\Temp\steenbuck\mcrCache9.9\matlab4\matlab_class\classificators\matlab_classifier_predict.m, line 11, in matlab_classifier_predict Undefined function 'istall' for input arguments of type 'double'.
File "C:\Program Files\MATLAB\MATLAB Runtime\v99\toolbox\compiler_sdk\pysdk_py\matlab_pysdk\runtime\futureresult.py", line 135, in result raise e File "C:\Program Files\MATLAB\MATLAB Runtime\v99\toolbox\compiler_sdk\pysdk_py\matlab_pysdk\runtime\futureresult.py", line 135, in result raise e File "C:\Program Files\MATLAB\MATLAB Runtime\v99\toolbox\compiler_sdk\pysdk_py\matlab_pysdk\runtime\futureresult.py", line 135, in result raise e File "C:\Program Files\MATLAB\MATLAB Runtime\v99\toolbox\compiler_sdk\pysdk_py\matlab_pysdk\runtime\deployablefunc.py", line 79, in __call__ ret = futureresult.FutureResult(self._cppext_handle, future_tuple, nlhs,