필터 지우기
필터 지우기

'cl.exe' is not recognized as an internal or external command,

조회 수: 44 (최근 30일)
sana3 sal
sana3 sal 2018년 5월 21일
댓글: Waqar Khan 2020년 5월 5일
Hello there,
Did anyone work with vlfeat library used in this tutorial : https://github.com/veda…/practical-object-category-detection ?
I passed to the step mentioned in the documentation
% Step 1.4: Apply the model to a test image
% -------------------------------------------------------------------------
im = imread('data/signs-sample-image.jpg') ;
im = im2single(im) ;
hog = vl_hog(im, hogCellSize) ;
scores = vl_nnconv(hog, w, []) ;
here the vl_nnconv(hog, w, []) ; function was having some error in its implementation, it was just a file that call another function called "vl_nnnotfound(mfilename);" and it has no arguments or any return value! but the function call has 3 arguments! so i altered the function to be as the attached file.
and it passed! but when calling the vl_nnnotfound function it return an error regarding the compiler of mingw-w64 with this error message:
'cl.exe' is not recognized as an internal or external command,
operable program or batch file.
Error using vl_compilenn>check_clpath (line 656)
Unable to find cl.exe
Error in vl_compilenn (line 426)
cl_path = fileparts(check_clpath()); % check whether cl.exe in path
I download the mingw-w64 compiler as a third party from the ads-on (matlab 2017b) and i find this compiler "TDM-GCC-64" but the same problem exists!!
Do I still have some error regarding its files and compilation with mingw-w64 compiler! they mentioned here : https://stackoverflow.com/questions/40226354/matconvnet-error-cl-exe-not-found
that i can use the Visual studio to use the cl.exe file in the path for comilation,
Does it work if i compiled it with visual studio?
NEED for HELP PLEASE!

답변 (3개)

Mohamed aymane Zizi
Mohamed aymane Zizi 2020년 1월 19일
The solution I figured out is hardcoding the path link.
in vl_compilenn.m file you find the line
cl_path = fullfile(cc.Location, 'VC', 'bin', 'amd64');
so basically you changed accordinally to where cl.exe is located, in my case I changed it to this.
cl_path = 'C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\bin\Hostx64\x64';
and worked perfectly!
wish that helps you!

Jan
Jan 2018년 5월 21일
편집: Jan 2018년 5월 21일
vlfeat does not support the MinGW compiler. According to the List of supported compilers for Matlab R2017b you need either a professional version of MSVC 2012, 2013 or 2015, or the community version of MSVC 2017.
See also: https://www.mathworks.com/matlabcentral/answers/331523-unable-to-find-cl-exe-executing-vl_compilenn . Note that searching in the forum is useful in many cases.
  댓글 수: 2
sana3 sal
sana3 sal 2018년 5월 21일
I have installed the community version of visual studio 2017, but still have the same error! after installing, what i have to do?
Jan
Jan 2018년 5월 22일
I suggest to ask the authors for help.

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


Walter Roberson
Walter Roberson 2018년 5월 21일
cl.exe not found usually means that you are trying to use a Visual Studio Express edition on a MATLAB version that needs the Professional edition.
  댓글 수: 2
sana3 sal
sana3 sal 2018년 5월 21일
i have installed the community version! does it matter?
Walter Roberson
Walter Roberson 2020년 3월 1일
Yes in your release it does matter.

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

카테고리

Help CenterFile Exchange에서 Introduction to Installation and Licensing에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by