Advertisement
Guest User

Untitled

a guest
Jun 25th, 2019
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.82 KB | None | 0 0
  1. Program received signal SIGSEGV, Segmentation fault.
  2. 0x0000000000409100 in std::string::_M_data() const ()
  3. Missing separate debuginfos, use: debuginfo-install glibc-2.17-260.el7_6.4.x86_64
  4. (gdb) where
  5. #0 0x0000000000409100 in std::string::_M_data() const ()
  6. #1 0x0000000000409170 in std::string::_M_rep() const ()
  7. #2 0x0000000000406c4c in std::string::length() const ()
  8. #3 0x0000000000404df6 in main ()
  9.  
  10. a:(.bss+0x1c0): multiple definition of `gMap'
  11. /tmp/cc0u5Onx.o:(.bss+0x60): first defined here
  12. a:(.rodata+0x0): multiple definition of `_IO_stdin_used'
  13. /lib/../lib64/crt1.o:(.rodata.cst4+0x0): first defined here
  14. a: In function `main':
  15. (.text+0x218c): multiple definition of `main'
  16. /tmp/cc0u5Onx.o:/home/ugrads/d/dhlaurel/ms_windows/cpsc_redirected/cmpSci/csce420/proj/proj1.cpp:621: first defined here
  17. a: In function `letterPicker(Network*)':
  18. (.text+0xe01): multiple definition of `letterPicker(Network*)'
  19. /tmp/cc0u5Onx.o:/home/ugrads/d/dhlaurel/ms_windows/cpsc_redirected/cmpSci/csce420/proj/proj1.cpp:345: first defined here
  20. a: In function `data_start':
  21. (.data+0x8): multiple definition of `__dso_handle'
  22. /opt/gcc8.2.0/bin/../lib/gcc/x86_64-pc-linux-gnu/8.2.0/crtbegin.o:(.data+0x0): first defined here
  23. a: In function `_fini':
  24. (.fini+0x0): multiple definition of `_fini'
  25. /lib/../lib64/crti.o:(.fini+0x0): first defined here
  26. a: In function `T()':
  27. (.text+0xe8): multiple definition of `T()'
  28. /tmp/cc0u5Onx.o:/home/ugrads/d/dhlaurel/ms_windows/cpsc_redirected/cmpSci/csce420/proj/proj1.cpp:19: first defined here
  29. a: In function `_start':
  30. (.text+0x0): multiple definition of `_start'
  31. /lib/../lib64/crt1.o:(.text+0x0): first defined here
  32. a: In function `_init':
  33. (.init+0x0): multiple definition of `_init'
  34. /lib/../lib64/crti.o:(.init+0x0): first defined here
  35. a: In function `gP(float)':
  36. (.text+0x114d): multiple definition of `gP(float)'
  37. /tmp/cc0u5Onx.o:/home/ugrads/d/dhlaurel/ms_windows/cpsc_redirected/cmpSci/csce420/proj/proj1.cpp:414: first defined here
  38. a: In function `data_start':
  39. (.data+0x0): multiple definition of `__data_start'
  40. /lib/../lib64/crt1.o:(.data+0x0): first defined here
  41. a: In function `valueOf(int)':
  42. (.text+0xf6): multiple definition of `valueOf(int)'
  43. /tmp/cc0u5Onx.o:/home/ugrads/d/dhlaurel/ms_windows/cpsc_redirected/cmpSci/csce420/proj/proj1.cpp:25: first defined here
  44. a: In function `data_start':
  45. (.data+0x18): multiple definition of `DEBUG'
  46. /tmp/cc0u5Onx.o:/home/ugrads/d/dhlaurel/ms_windows/cpsc_redirected/cmpSci/csce420/proj/proj1.cpp:19: first defined here
  47. a:(.bss+0x160): multiple definition of `solution'
  48. /tmp/cc0u5Onx.o:/home/ugrads/d/dhlaurel/ms_windows/cpsc_redirected/cmpSci/csce420/proj/proj1.cpp:19: first defined here
  49. a: In function `g(float)':
  50. (.text+0xfb9): multiple definition of `g(float)'
  51. /tmp/cc0u5Onx.o:/home/ugrads/d/dhlaurel/ms_windows/cpsc_redirected/cmpSci/csce420/proj/proj1.cpp:374: first defined here
  52. /opt/gcc8.2.0/bin/../lib/gcc/x86_64-pc-linux-gnu/8.2.0/crtend.o:(.tm_clone_table+0x0): multiple definition of `__TMC_END__'
  53. a:(.data+0x20): first defined here
  54. /usr/bin/ld: error in a(.eh_frame); no .eh_frame_hdr table will be created.
  55. collect2: error: ld returned 1 exit status
  56.  
  57. #include <iostream>
  58. #include <list>
  59. #include <map>
  60. #include <string>
  61. #include <vector>
  62. #include <random>
  63. #include <fstream>
  64. #include <numeric>
  65.  
  66.  
  67. int main()
  68. {
  69. int numLayers = 4; //at least 2
  70. int hiddLayerSize = 16;
  71. int inputSize;
  72. int outputSize;
  73. std::cout << "ERROR BLOCK 1";
  74. std::vector<std::vector< std::string > > letters;
  75. try{
  76. letters = bdfReader("ie9x14u.bdf");
  77. }catch (std::exception const &e){
  78. std::cout << "FILE READ ERRORn";
  79. return -1;
  80. }
  81.  
  82. std::vector<std::string> starLetters;
  83. std::cout << "ERROR BLOCK 2";
  84.  
  85. std::vector<std::string> letterInput = sampleInp(letters);
  86. std::vector<std::string> letterOutput = std::vector<std::string>(26, "00000000000000000000000000");
  87.  
  88. /* This was where I thought the problem might be occurring since it mentioned string errors, but after commenting it out, nothing happened
  89.  
  90. for (int i = 0; i < 26; i++) {
  91. letterOutput[i][i] = '1';
  92. }
  93. */
  94.  
  95.  
  96.  
  97.  
  98.  
  99. inputSize = letterInput[0].length();
  100. outputSize = letterOutput[0].length();
  101.  
  102.  
  103.  
  104. Network* letterNet = new Network(majorityInput, majorityOutput, numLayers, hiddLayerSize, inputSize, outputSize);
  105.  
  106.  
  107. std::pair<std::vector<std::string>, std::vector<std::string> > majExamp = std::pair<std::vector<std::string>, std::vector<std::string> >(majorityInput, majorityOutput);
  108.  
  109. std::pair<std::vector<std::string>, std::vector<std::string> > letterExamp = std::pair<std::vector<std::string>, std::vector<std::string> >(letterInput, letterOutput);
  110.  
  111. letterNet = backPropLearn(letterExamp, letterNet);
  112.  
  113. std::cout << weightsPrinter(letterNet);
  114. std::cout << std::to_string(networkAcc(letterExamp, letterNet)) + "* 100%n";
  115. std::cout << "n all done";
  116.  
  117.  
  118. return 0;
  119.  
  120. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement