Path issue mex on Mac 10.12.6 Matlab R2017a

3 visualizaciones (últimos 30 días)
Patrick Ford
Patrick Ford el 13 de Sept. de 2017
I am attempting to learn how to used GPU via Matlab using from "Accelerating MATLAB with GPU Computing" and I am getting the following error message:
Building with 'Xcode Clang++'. Error using mex ld: warning: ignoring file conv2Mex.obj, file was built for unsupported file format ( 0x64 0x86 0x0E 0x03 0x2D 0xC0 0xB6 0x51 0xF8 0x44 0x01 0x00 0xFD 0x09 0x00 0x00 ) which is not the architecture being linked (x86_64): conv2Mex.obj Undefined symbols for architecture x86_64: "conv2Mex(float*, float*, int, int, float*)", referenced from: mexFunction(int, mxArray_tag**, int, mxArray_tag**) in conv2MexCuda.o "_mexFunction", referenced from: -exported_symbol[s_list] command line option ld: symbol(s) not found for architecture x86_64 clang: error: linker command failed with exit code 1 (use -v to see invocation)
With this code:
% convol_cuda.m
system('nvcc -c conv2Mex.cu -ccbin "./nvcc') mex conv2MexCuda.cpp conv2Mex.obj -lcudart -L"/Developer/NVIDIA/CUDA-8.0/lib/"
quarters = single(imread('eight.tif')); kernel = single([1 2 1; 0 0 0; -1 -2 -1]); imagesc(quarters); colormap(gray);
H3 = conv2MexCuda(quarters, kernel); imagesc(H3); colormap(gray);
Best I can tell there is a path error and I would like to know how to fix it. Obviously my BASH skills need improvement.
Thanks

Respuestas (0)

Categorías

Más información sobre External Language Interfaces en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by