stanfordnlp / GloVe

Software in C and data files for the popular GloVe model for distributed word representations, a.k.a. word vectors or embeddings
Apache License 2.0
6.81k stars 1.51k forks source link

Typo mistake #176

Closed Genie-Liu closed 4 years ago

Genie-Liu commented 4 years ago

While I am looking into the source code, I find out there's a typo mistake which may cause null point exception if malloc fail. The if statement should check W_updates2 instead of W_updates1. I have created a PR to fix it. https://github.com/stanfordnlp/GloVe/pull/175

https://github.com/stanfordnlp/GloVe/blob/afd83fbf62b676d339c93639af1312b1b7626b53/src/glove.c#L174-L178

AngledLuffa commented 4 years ago

Excellent, thanks!