code: def _calc(self, h, t, r):
      t = t.view(-1, self.dim, 1)
      r = r.view(-1, self.dim, self.dim)
      tr = torch.matmul(r, t)
      tr = tr.view(-1, self.dim)
      return -torch.sum(h * tr, -1)
  
file_path: OpenKE/openke/module/model/RESCAL.py
imports: import torch
  import torch.nn
  from .Model import Model
label_desc: Use image node_id 2 for calling the RESCAL obj's underlying member method code with example usage: obj._calc(h, t, r) and returns: unknown