Question

i have a matlab code that run a c++ functions, it works well on my computer or any other desktop I've tried to run it on. (in order to run it on other desktop i copied the matlab/c++ functions and the mex files)

lately I've tried to run the code on a sge cluster but i get an error messege

"Undefined function 'img' for input arguments of type 'double'"

"img" is the c++ function called by matlab.

does anyone encountered the same problem? does anyone knows how to solve it?

10x Elad

Was it helpful?

Solution

It seems like you have different OS on laptop/desktop and SGE. For different architectures you need to re-mex your c++ code.

Configure mex on your sge

>> mex -setup

I strongly recommend using gcc. Now you can mex your c++ code. Note that the file extension for the mex files is different on windows/sge as well as 32bit and 64bit systems.

If you don't have the right extension for the mex file (can be checked using mexext command) Matlab cannot find the function to run and you get an error sinilar to what you got.

Happy Chanukah.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top