Corruption occurs when running SFMExample.m
Running line 51 of SFMExample.m will corrupt the matlab.
%% Print the graph graph.print(sprintf('\nFactor graph:\n'));
Comments (10)
-
-
reporter Hi Mike,
I am using Ubuntu 16.04 + Matlab 0217b. I have built and installed GTSAM 4.0 with matlab toolbox by following the readme file. The error I came across when running SFMExample.m is as below,
The error occurs when it proceeds line 51:
Print the graph graph.print(sprintf('\nFactor graph:\n'));
-
Okay, thanks. I will try to reproduce the error on my side and see if I can fix it. I'm on Ubuntu 16.04 with MATLAB 2018a, so my setup is pretty close to yours.
-
Even better would be to attach a text file with the stack dump, by pressing “details...” on the dialog and copy/pasting the whole thing.
-
reporter Hi Frank, here are the "details"
Segmentation violation detected at Wed Nov 28 21:37:43 2018
Configuration: Crash Decoding : Disabled - No sandbox or build area path Crash Mode : continue (default) Current Graphics Driver: Unknown hardware Current Visual : 0x46 (class 4, depth 24) Default Encoding : UTF-8 Deployed : false GNU C Library : 2.23 stable Host Name : zhouyi-ThinkPad-E480 MATLAB Architecture : glnxa64 MATLAB Entitlement ID: 6257193 MATLAB Root : /home/zhouyi/Software/MATLAB/R2017b MATLAB Version : 9.3.0.713579 (R2017b) OpenGL : hardware Operating System : Linux 4.15.0-39-generic
#42~16.04.1-Ubuntu SMP Wed Oct 24 17:09:54 UTC 2018 x86_64 Processor ID : x86 Family 6 Model 142 Stepping 10, GenuineIntel Virtual Machine : Java 1.8.0_121-b13 with Oracle Corporation Java HotSpot(TM) 64-Bit Server VM mixed mode Window System : The X.Org Foundation (11906000), display :0Fault Count: 1
Abnormal termination: Segmentation violation
Register State (from fault): RAX = 00000000ffffffff RBX = 000000000000000b RCX = 00007f8b97e227f8 RDX = 00007f8c63ffb050 RSP = 00007f8c63ffadd0 RBP = 00007f8c63ffaf60 RSI = 00007f8b97e25108 RDI = 00007f8c63ffaef8
R8 = 0000000000000000 R9 = 0000000000000000 R10 = cccccccccccccccd R11 = 0000000000001002 R12 = 00007f8c63ffb050 R13 = 00007f8c63ffaf68 R14 = 00007f8b0cbc34a0 R15 = 00007f8c63ffb060
RIP = 00007f8c88e5a8e3 EFL = 0000000000010206
CS = 0033 FS = 0000 GS = 0000
Stack Trace (from fault): [ 0] 0x00007f8c88e5a8e3 /usr/lib/x86_64-linux-gnu/libstdc++.so.6+00674019 ZNSt6localeD1Ev+00000019 [ 1] 0x00007f8b07bbdc9c /usr/local/lib/libgtsam.so.4+01662108 _ZNK5gtsam6SymbolcvNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEB5cxx11Ev+00000540 [ 2] 0x00007f8b07bb9f7b /usr/local/lib/libgtsam.so.4+01646459 _ZN5gtsam20_defaultKeyFormatterB5cxx11Em+00000331 [ 3] 0x00007f8b0c6d3db0 /home/zhouyi/workspace/project/gtsam/matlab_toolbox/gtsam_wrapper.mexa64+06155696 _ZN5boost6detail8function17function_invoker1IPFNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEmES8_mE6invokeERNS1_15function_bufferEm+00000032 [ 4] 0x00007f8b07cfcc66 /usr/local/lib/libgtsam.so.4+02968678 _ZNK5gtsam15NonlinearFactor5printERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKN5boost8functionIFS6_mEEE+00000166 [ 5] 0x00007f8b07cfcdb0 /usr/local/lib/libgtsam.so.4+02969008 _ZNK5gtsam16NoiseModelFactor5printERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKN5boost8functionIFS6_mEEE+00000032 [ 6] 0x00007f8b0c6fb6f1 /home/zhouyi/workspace/project/gtsam/matlab_toolbox/gtsam_wrapper.mexa64+06317809 _ZNK5gtsam23GenericProjectionFactorINS_5Pose3ENS_6Point3ENS_7Cal3_S2EE5printERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKN5boost8functionIFSA_mEEE+00000193 [ 7] 0x00007f8b07d00962 /usr/local/lib/libgtsam.so.4+02984290 _ZNK5gtsam20NonlinearFactorGraph5printERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKN5boost8functionIFS6_mEEE+00001122 [ 8] 0x00007f8b0c5af7bd /home/zhouyi/workspace/project/gtsam/matlab_toolbox/gtsam_wrapper.mexa64+04958141 _Z36gtsamNonlinearFactorGraph_print_1110iPP11mxArray_tagiPPKS+00000173 [ 9] 0x00007f8b0c6ccc07 /home/zhouyi/workspace/project/gtsam/matlab_toolbox/gtsam_wrapper.mexa64+06126599 mexFunction+00043991 [ 10] 0x00007f8c75b5c3c7 bin/glnxa64/libmex.so+00172999 mexRunMexFile+00000439 [ 11] 0x00007f8c75b55c23 bin/glnxa64/libmex.so+00146467 [ 12] 0x00007f8c75b56385 bin/glnxa64/libmex.so+00148357 [ 13] 0x00007f8c778c7c83 bin/glnxa64/libmwm_dispatcher.so+00830595 ZN8Mfh_file16dispatch_fh_implEMS_FviPP11mxArray_tagiS2_EiS2_iS2+00000947 [ 14] 0x00007f8c778c854e bin/glnxa64/libmwm_dispatcher.so+00832846 ZN8Mfh_file11dispatch_fhEiPP11mxArray_tagiS2+00000030 [ 15] 0x00007f8c73f3390a bin/glnxa64/libmwm_lxe.so+12519690 [ 16] 0x00007f8c73f34d9e bin/glnxa64/libmwm_lxe.so+12524958 [ 17] 0x00007f8c73ff58c9 bin/glnxa64/libmwm_lxe.so+13314249 [ 18] 0x00007f8c73f9af01 bin/glnxa64/libmwm_lxe.so+12943105 [ 19] 0x00007f8c73882e50 bin/glnxa64/libmwm_lxe.so+05504592 [ 20] 0x00007f8c738850e4 bin/glnxa64/libmwm_lxe.so+05513444 [ 21] 0x00007f8c738818d1 bin/glnxa64/libmwm_lxe.so+05499089 [ 22] 0x00007f8c7387d861 bin/glnxa64/libmwm_lxe.so+05482593 [ 23] 0x00007f8c7387dc89 bin/glnxa64/libmwm_lxe.so+05483657 [ 24] 0x00007f8c73881100 bin/glnxa64/libmwm_lxe.so+05497088 [ 25] 0x00007f8c738811cf bin/glnxa64/libmwm_lxe.so+05497295 [ 26] 0x00007f8c739811d1 bin/glnxa64/libmwm_lxe.so+06545873 [ 27] 0x00007f8c73983f53 bin/glnxa64/libmwm_lxe.so+06557523 [ 28] 0x00007f8c73e334ce bin/glnxa64/libmwm_lxe.so+11470030 [ 29] 0x00007f8c73f24f1e bin/glnxa64/libmwm_lxe.so+12459806 [ 30] 0x00007f8c778c7c83 bin/glnxa64/libmwm_dispatcher.so+00830595 ZN8Mfh_file16dispatch_fh_implEMS_FviPP11mxArray_tagiS2_EiS2_iS2+00000947 [ 31] 0x00007f8c778c854e bin/glnxa64/libmwm_dispatcher.so+00832846 ZN8Mfh_file11dispatch_fhEiPP11mxArray_tagiS2+00000030 [ 32] 0x00007f8c73f3390a bin/glnxa64/libmwm_lxe.so+12519690 [ 33] 0x00007f8c73f34d9e bin/glnxa64/libmwm_lxe.so+12524958 [ 34] 0x00007f8c73ff58c9 bin/glnxa64/libmwm_lxe.so+13314249 [ 35] 0x00007f8c73f9af01 bin/glnxa64/libmwm_lxe.so+12943105 [ 36] 0x00007f8c73882e50 bin/glnxa64/libmwm_lxe.so+05504592 [ 37] 0x00007f8c738850e4 bin/glnxa64/libmwm_lxe.so+05513444 [ 38] 0x00007f8c738818d1 bin/glnxa64/libmwm_lxe.so+05499089 [ 39] 0x00007f8c7387d861 bin/glnxa64/libmwm_lxe.so+05482593 [ 40] 0x00007f8c7387dc89 bin/glnxa64/libmwm_lxe.so+05483657 [ 41] 0x00007f8c73881100 bin/glnxa64/libmwm_lxe.so+05497088 [ 42] 0x00007f8c738811cf bin/glnxa64/libmwm_lxe.so+05497295 [ 43] 0x00007f8c739811d1 bin/glnxa64/libmwm_lxe.so+06545873 [ 44] 0x00007f8c73983f53 bin/glnxa64/libmwm_lxe.so+06557523 [ 45] 0x00007f8c73e334ce bin/glnxa64/libmwm_lxe.so+11470030 [ 46] 0x00007f8c73df88fa bin/glnxa64/libmwm_lxe.so+11229434 [ 47] 0x00007f8c73df8e78 bin/glnxa64/libmwm_lxe.so+11230840 [ 48] 0x00007f8c73dfa6e2 bin/glnxa64/libmwm_lxe.so+11237090 [ 49] 0x00007f8c73e7024e bin/glnxa64/libmwm_lxe.so+11719246 [ 50] 0x00007f8c73e705da bin/glnxa64/libmwm_lxe.so+11720154 [ 51] 0x00007f8c75d99a8e bin/glnxa64/libmwbridge.so+00199310 _Z8mnParserv+00000862 [ 52] 0x00007f8c77d96793 bin/glnxa64/libmwmcr.so+00558995 [ 53] 0x00007f8c77d9892e bin/glnxa64/libmwmcr.so+00567598 [ 54] 0x00007f8c77d99099 bin/glnxa64/libmwmcr.so+00569497 _ZN5boost6detail17task_shared_stateINS_3_bi6bind_tIvPFvRKNS_8functionIFvvEEEENS2_5list1INS2_5valueIS6_EEEEEEvE6do_runEv+00000025 [ 55] 0x00007f8c77d978b6 bin/glnxa64/libmwmcr.so+00563382 [ 56] 0x00007f8c7877b259 bin/glnxa64/libmwiqm.so+00860761 [ 57] 0x00007f8c78767b6c bin/glnxa64/libmwiqm.so+00781164 _ZN5boost6detail8function21function_obj_invoker0ISt8functionIFNS_3anyEvEES4_E6invokeERNS1_15function_bufferE+00000028 [ 58] 0x00007f8c7876784c bin/glnxa64/libmwiqm.so+00780364 _ZN3iqm18PackagedTaskPlugin7executeEP15inWorkSpace_tagRN5boost10shared_ptrIN14cmddistributor17IIPCompletedEventEEE+00000428 [ 59] 0x00007f8c787458b8 bin/glnxa64/libmwiqm.so+00641208 [ 60] 0x00007f8c7873353f bin/glnxa64/libmwiqm.so+00566591 [ 61] 0x00007f8c78735759 bin/glnxa64/libmwiqm.so+00575321 [ 62] 0x00007f8c87c7caba bin/glnxa64/libmwservices.so+02702010 [ 63] 0x00007f8c87c7e06f bin/glnxa64/libmwservices.so+02707567 [ 64] 0x00007f8c87c7e81a bin/glnxa64/libmwservices.so+02709530 _Z25svWS_ProcessPendingEventsiib+00000186 [ 65] 0x00007f8c77d96f0e bin/glnxa64/libmwmcr.so+00560910 [ 66] 0x00007f8c77d972b4 bin/glnxa64/libmwmcr.so+00561844 [ 67] 0x00007f8c77d84c06 bin/glnxa64/libmwmcr.so+00486406 [ 68] 0x00007f8c86f286ba /lib/x86_64-linux-gnu/libpthread.so.0+00030394 [ 69] 0x00007f8c86c5e41d /lib/x86_64-linux-gnu/libc.so.6+01078301 clone+00000109 [ 70] 0x0000000000000000 <unknown-module>+00000000
This error was detected while a MEX-file was running. If the MEX-file is not an official MathWorks function, please examine its source code for errors. Please consult the External Interfaces Guide for information on debugging MEX-files.
If this problem is reproducible, please submit a Service Request via: http://www.mathworks.com/support/contact_us/
A technical support engineer might contact you with further information.
Thank you for your help.
-
OK, that's useful. Seems
defaultKeyFormatter
is the function that is crashing, called fromNonlinearFactorGraph::print
-
Note, on Mac this is not an issue. Mike, did you see the same issue with MATLAb 2018? If not, perhaps close this issue as wontfix and reccomend upgrading MATLAB.
-
I'll check
-
Okay, I just ran
SFMExample.m
againstHEAD
ofdevelop
in MATLAB 2018b on Ubuntu 16.014 on x86_64 and didn't see any issues. Recommendwontfix
. -
- changed status to wontfix
Mike just ran SFMExample.m against HEAD of develop in MATLAB 2018b on Ubuntu 16.014 on x86_64 and didn't see any issues.
- Log in to comment
Can you elaborate on
corrupt the matlab
? If you could paste the error you see here, that would be great. Thanks!