alex-tifrea / poincare_glove

Implementation of the "Poincare Glove: Hyperbolic word embeddings" paper
GNU Lesser General Public License v2.1
83 stars 20 forks source link

Segmentation Fault (core dumped) #1

Closed taku-ito closed 5 years ago

taku-ito commented 5 years ago

During Poincare embeddings training, the program often exits with a segmentation fault (core dumped) message.

[1073746064, 1073746480] Cannot compute Poincare distance between points. Points need to be inside the unit ball, but their squared norm is -nan and 0.999980.
zsh: segmentation fault (core dumped)  python3 glove_code/scripts/glove_main_es.py --train --root=..   --size=100

I'm using Ubuntu 18.04 with python 3.6.5.

Could you please let me know how to resolve this issue? Thanks!

alex-tifrea commented 5 years ago

Hi,

The cause of the segfault is likely the numerical error that is logged above it. That happens when the embeddings are pushed too close to the border of the Poincaré ball. You can try to use a smaller learning rate, or to make sure they are initialize close to the border.

taku-ito commented 5 years ago

Thank you for your quick response.