When I run demo-phrases.sh on Linux I get the following error message:
./demo-phrases.sh: line 6: 5492 Segmentation fault ./word2phrase -train text8 -output text8-phrase -threshold 500 -debug 2
Comment #1
Posted on Sep 13, 2013 by Happy Horsehaving the same. Compiled with gcc47 on amazon standard image. word2vec works fine.
Comment #2
Posted on Nov 17, 2013 by Grumpy Kangarooditto
Comment #3
Posted on Nov 17, 2014 by Massive RhinoHit this as well and found the box out of memory and no swap configured might want to check for NULL on mallocs
Comment #4
Posted on Apr 8, 2015 by Swift HorseI am getting the same segmentation problem. I am trying to run demo-word.sh on Unbuntu, which is installed on a Virtual Machine on Mac OSX.
I tried compiling with gcc4.7 on Ubuntu, but it does not work for me.
When I check out the C code for word2vec and run "make" on trunk, I get the following warning messages:
dev@dev-VirtualBox:~/text-analytics/trunk$ make gcc word2vec.c -o word2vec -lm -pthread -O3 -march=native -Wall -funroll-loops -Wno-unused-result gcc word2phrase.c -o word2phrase -lm -pthread -O3 -march=native -Wall -funroll-loops -Wno-unused-result gcc distance.c -o distance -lm -pthread -O3 -march=native -Wall -funroll-loops -Wno-unused-result distance.c: In function ‘main’: distance.c:31:8: warning: unused variable ‘ch’ [-Wunused-variable] char ch; ^ gcc word-analogy.c -o word-analogy -lm -pthread -O3 -march=native -Wall -funroll-loops -Wno-unused-result word-analogy.c: In function ‘main’: word-analogy.c:31:8: warning: unused variable ‘ch’ [-Wunused-variable] char ch; ^ gcc compute-accuracy.c -o compute-accuracy -lm -pthread -O3 -march=native -Wall -funroll-loops -Wno-unused-result compute-accuracy.c: In function ‘main’: compute-accuracy.c:29:109: warning: unused variable ‘ch’ [-Wunused-variable] char st1[max_size], st2[max_size], st3[max_size], st4[max_size], bestw[N][max_size], file_name[max_size], ch; ^ chmod +x *.sh
Does anyone have any suggestions?
Status: New
Labels:
Type-Defect
Priority-Medium