fix the name of variable
@@ -611,9 +611,9 @@ class KgeModel(KgeBase):
)
# penalize recriprocal relations if reciprocal model is used
if kwargs["is_reciprocal_model"]:
- indexes = triples[:, P] + int(self.dataset.num_relations() / 2)
+ recriprocal_indexes = triples[:, P] + int(self.dataset.num_relations() / 2)
penalty_result += self.get_p_embedder().penalty(
- indexes=indexes, **kwargs
+ indexes=recriprocal_indexes, **kwargs
)
if self.get_s_embedder() is self.get_o_embedder():
weighted = self.get_s_embedder().get_option("regularize_args.weighted")
