graphvite icon indicating copy to clipboard operation
graphvite copied to clipboard

Could you explain what are vertex matrix and context matrix?

Open HenryYihengXu opened this issue 4 years ago • 8 comments

I'm reading your paper and have a question about section 3.2. Could you explain what are the vertex matrix and context matrix? Are they simply the source and the destination of edges?

HenryYihengXu avatar Feb 12 '20 03:02 HenryYihengXu

Yes. Every node has a vertex and a context embedding. Vertex embedding is used when it acts as a source node, and context embedding is used for destination node.

KiddoZhu avatar Feb 14 '20 21:02 KiddoZhu

Are you saying each node will have two embedding vectors? So the number of embeddings will be twice as the number of nodes?

I don't quite understand the figure 2 in your Graphvite paper. In the figure, you have 4 GPUs and you divide the sample pool into 4x4 grids. Grid (i,j) contains edges with source in vertex i and dest in context j right? So what is the episode size here? Does it indicate that it takes many episodes to compute a single grid?

HenryYihengXu avatar Feb 15 '20 16:02 HenryYihengXu

And by your sampling method, each grid could contain different numbers of edges right?

HenryYihengXu avatar Feb 15 '20 17:02 HenryYihengXu

For the embedding, yes.

The episode size is the number of batch in a grid, e.g. 500 for Youtube dataset. Each grid contains episode size * batch size positive samples. The is mainly because a sufficiently large grid is needed to reduce swap of embedding parameters across GPUs.

KiddoZhu avatar Feb 21 '20 05:02 KiddoZhu

@KiddoZhu What's the purpose of setting two embedding vectors for each node?

razrLeLe avatar Mar 02 '20 11:03 razrLeLe

One vector is called vertex representation, the other is called context representation. This is mainly borrowed from the distributional hypothesis in NLP.

Empirically it works better than tied vertex and context parameters.

KiddoZhu avatar Mar 07 '20 22:03 KiddoZhu

One vector is called vertex representation, the other is called context representation. This is mainly borrowed from the distributional hypothesis in NLP.

Empirically it works better than tied vertex and context parameters.

hi,when I use them, how do I choose vertex embeddings or context embeddings?

HJW3536 avatar Apr 01 '21 07:04 HJW3536

One vector is called vertex representation, the other is called context representation. This is mainly borrowed from the distributional hypothesis in NLP. Empirically it works better than tied vertex and context parameters.

hi,when I use them, how do I choose vertex embeddings or context embeddings?

vertex embeddings is better

chi2liu avatar Apr 29 '22 07:04 chi2liu