ttrouill/complex

about the appendix A and B of the essay

Misoknisky opened this issue · 2 comments

There is no trace about appendix A and appendix B of the Complex Embeddings for Simple Link Prediction

Hello,
Indeed Appendix A describes the full SGD algorithm with gradients and all, this implementation is theano-based and hence uses auto-differentiation, that's why you'll see no trace of gradients in this code: it only needs to know the loss. Appendix A is here to help people implement the model by themselves, it is not a description of this implementation.
PCA plots of Appendix B are not provided here, if you want to reproduce them you can easily access the real (r1) and imaginary (r2) parts of the relation embeddings once the model is trained in wn18_run.py via:

word_embs_exp.models["Complex_Logistic_Model"][0].r1.get_value(borrow=True)
word_embs_exp.models["Complex_Logistic_Model"][0].r2.get_value(borrow=True)

and then use your favorite PCA tool to visualize them.

Thanks for your patience!!!!