Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error while running 'compile_mathconvnet' #4

Closed
cemysf opened this issue Oct 25, 2016 · 1 comment
Closed

error while running 'compile_mathconvnet' #4

cemysf opened this issue Oct 25, 2016 · 1 comment

Comments

@cemysf
Copy link

cemysf commented Oct 25, 2016

Hi,

I'm getting this error while running compile_mathconvnet script in windows 7, using matlab r2016b with mingw as mex compiler:

>> compile_matconvnet
Starting parallel pool (parpool) using the 'local' profile ... connected to 2 workers.
Building with 'MinGW64 Compiler (C++)'.
MEX completed successfully.
Building with 'MinGW64 Compiler (C++)'.
MEX completed successfully.
Building with 'MinGW64 Compiler (C++)'.
MEX completed successfully.
Building with 'MinGW64 Compiler (C++)'.
MEX completed successfully.
Building with 'MinGW64 Compiler (C++)'.
MEX completed successfully.
Building with 'MinGW64 Compiler (C++)'.
In file included from X:\github\MDNet\matconvnet\matlab\src\bits\datamex.cpp:4:0:
X:\github\MDNet\matconvnet\matlab\src\bits\datamex.cu: In member function 'vl::Error vl::MexTensor::init(vl::Device, const vl::TensorGeometry&)':
X:\github\MDNet\matconvnet\matlab\src\bits\datamex.cu:177:43: warning: narrowing conversion of '(& geom)->vl::TensorGeometry::getHeight()' from 'vl::index_t {aka int}' to 'mwSize {aka long long unsigned int}' inside { } [-Wnarrowing]
   mwSize dimensions [4] = {geom.getHeight(),
                                           ^
X:\github\MDNet\matconvnet\matlab\src\bits\datamex.cu:178:42: warning: narrowing conversion of '(& geom)->vl::TensorGeometry::getWidth()' from 'vl::index_t {aka int}' to 'mwSize {aka long long unsigned int}' inside { } [-Wnarrowing]
                            geom.getWidth(),
                                          ^
X:\github\MDNet\matconvnet\matlab\src\bits\datamex.cu:179:42: warning: narrowing conversion of '(& geom)->vl::TensorGeometry::getDepth()' from 'vl::index_t {aka int}' to 'mwSize {aka long long unsigned int}' inside { } [-Wnarrowing]
                            geom.getDepth(),
                                          ^
X:\github\MDNet\matconvnet\matlab\src\bits\datamex.cu:180:41: warning: narrowing conversion of '(& geom)->vl::TensorGeometry::getSize()' from 'vl::index_t {aka int}' to 'mwSize {aka long long unsigned int}' inside { } [-Wnarrowing]
                            geom.getSize()} ;
                                         ^
X:\github\MDNet\matconvnet\matlab\src\bits\datamex.cu: In member function 'vl::Error vl::MexTensor::initWithZeros(vl::Device, const vl::TensorGeometry&)':
X:\github\MDNet\matconvnet\matlab\src\bits\datamex.cu:233:43: warning: narrowing conversion of '(& geom)->vl::TensorGeometry::getHeight()' from 'vl::index_t {aka int}' to 'mwSize {aka long long unsigned int}' inside { } [-Wnarrowing]
   mwSize dimensions [4] = {geom.getHeight(),
                                           ^
X:\github\MDNet\matconvnet\matlab\src\bits\datamex.cu:234:42: warning: narrowing conversion of '(& geom)->vl::TensorGeometry::getWidth()' from 'vl::index_t {aka int}' to 'mwSize {aka long long unsigned int}' inside { } [-Wnarrowing]
                            geom.getWidth(),
                                          ^
X:\github\MDNet\matconvnet\matlab\src\bits\datamex.cu:235:42: warning: narrowing conversion of '(& geom)->vl::TensorGeometry::getDepth()' from 'vl::index_t {aka int}' to 'mwSize {aka long long unsigned int}' inside { } [-Wnarrowing]
                            geom.getDepth(),
                                          ^
X:\github\MDNet\matconvnet\matlab\src\bits\datamex.cu:236:41: warning: narrowing conversion of '(& geom)->vl::TensorGeometry::getSize()' from 'vl::index_t {aka int}' to 'mwSize {aka long long unsigned int}' inside { } [-Wnarrowing]
                            geom.getSize()} ;
                                         ^

MEX completed successfully.
Building with 'MinGW64 Compiler (C++)'.
MEX completed successfully.
Building with 'MinGW64 Compiler (C++)'.
MEX completed successfully.
Building with 'MinGW64 Compiler (C++)'.
MEX completed successfully.
Building with 'MinGW64 Compiler (C++)'.
MEX completed successfully.
Building with 'MinGW64 Compiler (C++)'.
MEX completed successfully.
Building with 'MinGW64 Compiler (C++)'.
MEX completed successfully.
Building with 'MinGW64 Compiler (C++)'.
MEX completed successfully.
Building with 'MinGW64 Compiler (C++)'.
MEX completed successfully.
Building with 'MinGW64 Compiler (C++)'.
MEX completed successfully.
Building with 'MinGW64 Compiler (C++)'.
Error using vl_compilenn>mex_compile (line 411)
X:\github\MDNet\matconvnet\matlab\src\bits\impl\imread_gdiplus.cpp: In member function 'vl::Image
vl::ImageReader::Impl::read(const char*, float*)':
X:\github\MDNet\matconvnet\matlab\src\bits\impl\imread_gdiplus.cpp:91:83: error: 'mbstowcs_s' was not
declared in this scope
   mbstowcs_s(&n, filenamew, sizeof(filenamew)/sizeof(wchar_t), filename, _TRUNCATE);
                                                                                   ^
X:\github\MDNet\matconvnet\matlab\src\bits\impl\imread_gdiplus.cpp: In member function 'vl::Image
vl::ImageReader::Impl::readDimensions(const char*)':
X:\github\MDNet\matconvnet\matlab\src\bits\impl\imread_gdiplus.cpp:149:83: error: 'mbstowcs_s' was
not declared in this scope
   mbstowcs_s(&n, filenamew, sizeof(filenamew)/sizeof(wchar_t), filename, _TRUNCATE);
                                                                                   ^


Error in vl_compilenn (line 371)
parfor i = 1:numel(horzcat(lib_src, mex_src))

Error in compile_matconvnet (line 13)
vl_compilenn;
@cemysf
Copy link
Author

cemysf commented Oct 26, 2016

nevermind, switched to ubuntu, it works now

i'm guessing something is wrong with the mingw compiler, or windows

@cemysf cemysf closed this as completed Oct 26, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant