I’ve a question regarding the pinsage model. I tried using the movie lens data.I see that Following is the model created.
PinSAGEModel(
(proj): LinearProjector(
(inputs): ModuleDict(
(year): Embedding(82, 64, padding_idx=81)
(genre): Linear(in_features=18, out_features=64, bias=True)
(id): Embedding(3707, 64, padding_idx=3706)
(title): BagOfWords(
(emb): Embedding(4946, 64, padding_idx=1)
)
)
)
(sage): SAGENet(
(convs): ModuleList(
(0): WeightedSAGEConv(
(Q): Linear(in_features=64, out_features=64, bias=True)
(W): Linear(in_features=128, out_features=64, bias=True)
(dropout): Dropout(p=0.5, inplace=False)
)
(1): WeightedSAGEConv(
(Q): Linear(in_features=64, out_features=64, bias=True)
(W): Linear(in_features=128, out_features=64, bias=True)
(dropout): Dropout(p=0.5, inplace=False)
)
)
)
(scorer): ItemToItemScorer()
)
However I don’t see the user features not being used here. In the preprocess_movielens.py file, features for the user are assigned. But I don’t see them being used in the model.
g.nodes['user'].data['gender'] = torch.LongTensor(users['gender'].cat.codes.values)
g.nodes['user'].data['age'] = torch.LongTensor(users['age'].cat.codes.values)
g.nodes['user'].data['occupation'] = torch.LongTensor(users['occupation'].cat.codes.values)
g.nodes['user'].data['zip'] = torch.LongTensor(users['zip'].cat.codes.values)
Can you please help me understand?
@BarclayII