tail_predict¶
- unike.config.tail_predict(batch: dict[str, Union[dgl.DGLGraph, torch.Tensor]], model: Model) tuple[torch.Tensor, ...][源代码]¶
进行尾实体的链接预测。
- 参数:
batch (dict[str, Union[dgl.DGLGraph, torch.Tensor]]) – 测试数据
model (unike.module.model.Model) – KGE 模型
- 返回:
正确三元组的排名
- 返回类型:
tuple[torch.Tensor, …]