- Open the file svm_common.h located in the svm_light directory.
- Find the line that contains the “sizeof” operator and check for any syntax errors or inconsistencies.
- Make sure that the syntax of the “sizeof” operator is correct. It should be in the form “sizeof(type)”.
- Save the file after making any necessary corrections.
error using mex while running svm struct
2 ビュー (過去 30 日間)
古いコメントを表示
Hello,
I just started with Matlab and have a problem istalling the following package.
I am using MATLAB R2023a and I try to install A MATLAB wrapper of SVMstruct, A. Vedaldi, http://www.vlfeat.org/~vedaldi/code/svm-struct-matlab.html, 2008..
Therefore I downloaded the Git repository and Visual C. After run the followin command:
run('//.../svm-struct-matlab-master/makefile_windows.m')
I got the following error:
doing hideo
Building with 'Microsoft Visual C++ 2022 ©'.
Error using mex
svm_hideo.c
\\...svm-struct-matlab-master\svm_light\svm_common.h(447): error C2059: Syntaxfehler: "sizeof"
Error in makefile windows (line 3)
mex -largeArrayDims -c -DWIN ./svm_light/svm_hideo.c
Error in run (line 91)
evalin('caller', strcat(script, ';'));
Thank everyone for your help.
0 件のコメント
回答 (1 件)
Raghav
2023 年 8 月 4 日
Hi Luise,
The error you encountered suggests that there is a syntax error in the file “svm_common.h” located in the svm_light directory of the SVMstruct MATLAB wrapper. This error is related to the use of the “sizeof” operator in that file.
To resolve this issue, you can try the following steps:
Once you've made the changes, try running the “makefile_windows.m” script again. If the error persists, please provide more information about the specific line in “svm_common.h” since that is causing the error.
Hope it helps,
Best Regards,
Raghav Bansal
MathWorks Technical Support
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Software Development Tools についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!