code: def calc_score(self, embedding, triplets):
      s = embedding[triplets[:, 0]]
      r = self.w_relation[triplets[:, 1]]
      o = embedding[triplets[:, 2]]
      score = torch.sum(s * r * o, dim=1)
      return score
  
imports: import dgl
  import numpy
  import torch
  import torch.nn
  import torch.nn.functional
  import tqdm
  from dgl.data.knowledge_graph import FB15k237Dataset
  from dgl.dataloading import GraphDataLoader
  from dgl.nn.pytorch import RelGraphConv
label_desc: Use image node_id 2 for calling the LinkPredict obj's underlying member method code with example usage: obj.calc_score(embedding, triplets) and returns: score