omadesala / word2vec

Automatically exported from code.google.com/p/word2vec
Apache License 2.0
0 stars 0 forks source link

expTable array initialization #24

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
In the end of word2vec.c there's "malloc" of size EXP_TABLE_SIZE + 1

But the next "for" loop is for(i=0; i < EXP_TABLE_SIZE; ++i)

That means, expTable[EXP_TABLE_SIZE] is uninitialized.

As the result - we can see different program output on the same input data.

Original issue reported on code.google.com by alex.y.t...@gmail.com on 1 Dec 2014 at 7:11