class_docstr: Calculate score of triplet (h, r, t) based on pretained KG embeddings
      using specified score_function
  Parameters
  ---------
  device : int
      Device to run the inference, -1 for CPU
  config : dict
      Containing KG model information
  model_path : str
      path storing the model (pretrained embeddings)
  score_func : str
      What kind of score is used,
          none: score = $x$
          logsigmoid: score $log(sigmoid(x))
class_docstr_tok: ["Calculate","score","of","triplet","(","h",",","r",",","t",")","based","on","pretained","KG","embeddings","using","specified","score_function","Parameters","--","--","--","--","-","device",":","int","Device","to","run","the","inference",",","-1","for","CPU","config",":","dict","Containing","KG","model","information","model_path",":","str","path","storing","the","model","(","pretrained","embeddings",")","score_func",":","str","What","kind","of","score","is","used",",","none",":","score","=","$","x","$","logsigmoid",":","score","$","log","(","sigmoid","(","x",")",")"]
code: def load_model(self):
      config = self.config
      model_path = self.model_path
      # for none score func, use 0.
      # for logsigmoid use original gamma to make the score closer to 0.
      gamma = config["gamma"] if self.sfunc == "logsigmoid" else 0.0
      model = InferModel(
          device=self.device,
          model_name=config["model"],
          hidden_dim=config["emb_size"],
          double_entity_emb=config["double_ent"],
          double_relation_emb=config["double_rel"],
          gamma=gamma,
      )
      dataset = config["dataset"]
      model.load_emb(model_path, dataset)
      self.model = model
  
file_path: ogb/examples/lsc/wikikg90m/dgl-ke-ogb-lsc/python/dglke/models/infer.py
imports: import os
  import time
  import argparse
  import numpy
  import dgl.backend
  from .general_models import InferModel
label_desc: Use image node_id 2 for calling the ScoreInfer obj's underlying member method code with example usage: obj.load_model() without return types