필터 지우기
필터 지우기

MEXCallMatlab very slow. Suggest alternate

조회 수: 1 (최근 30일)
Harshit
Harshit 2012년 11월 30일
Hi, I am working on a MEX file. I am using MEXCallMatlab which is very slow to call matlab inbuilt function as well as user defined function. It is not possible for me to make mex for other files since they are in large number and each of them is calling many in-built. Thanks.

채택된 답변

Jan
Jan 2012년 11월 30일
mexCallMATLAB is slow. Calling built-in Matlab functions from a MEX is no good idea.
  댓글 수: 4
Harshit
Harshit 2013년 4월 4일
Yes James. It is what happening.
Jan
Jan 2013년 4월 4일
When the main time is spent for the callimng of Matlab from inside the MEX function, and you need to call a lot of Matlab functions which call other builtins again, using a MEX-file is not an efficient approach. E.g. the creation of a usual GUI is not noticably faster when it is created as MEX function, because the creation of the UI-elements needs most of the time.
Therefore a good strategy is to find the bottlenecks of your program at first and use MEX files only for "basic" calculations.

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 MATLAB Compiler에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by