-
Hi, I have been working off one of the unsupervised bipartite examples. I was wondering if there is a way to structure the network so that the node representation for the two different nodes are on the same vector space. Currently I am able to perform cosine similarity within each node types. I would like to extract the embeddings and perform cosine similarity to find nearest neighbours across the different node types. Any help is appreciated. Thanks in advance
|
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
You can modify the model to have a single encoder that processes both node types together. This can be done by concatenating the feature tensors of the two node types along the node dimension and passing them through a shared encoder. something like this:
|
Beta Was this translation helpful? Give feedback.
-
Thanks for your reply! I am assuming this only works if the features for user and item have the same dimension? Is there a way to get around that constraint? Thanks |
Beta Was this translation helpful? Give feedback.
-
For any one who is interested I solved this by using a simple classifier that performs dot product rather than the edge decoder stated above. Also linear layers to the model to handle different features dimensions for the different node types.
|
Beta Was this translation helpful? Give feedback.
For any one who is interested I solved this by using a simple classifier that performs dot product rather than the edge decoder stated above.
Also linear layers to the model to handle different features dimensions for the different node types.