This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""kw-techtip-04-03-2013-p3.py | |
Compute BoW representations and train / test a SVM classifier in a N-fold | |
cross-validation setup. | |
Usage | |
----- | |
$ python kw-techtip-04-03-2013-p3.py <DataFile> <IndexFile> <ClassInfoFile> | |
""" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1) Compile your code (using mex) with -g flag | |
2) Call gdb via MATLAB's 'matlab -Dgdb' functionality | |
3) Set a breakpoint for instance by 'break testfile.cpp:9' | |
3) Run MATLAB without the JVM by 'run -nojvm' | |
4) Now, run the segfaulting mex function | |
5) Get a backtrace via 'bt' and use your debugging magic | |
Example: | |
$ cd '/mycode/ |
NewerOlder