Skip to content

Commit 9a6b712

Browse files
committed
style: fix typo
1 parent fd8a66e commit 9a6b712

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

pyrdf2vec/samplers/wide.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ def get_weight(self, hop: Hop) -> float:
8181
Args:
8282
hop: The hop of a vertex in a (predicate, object) form to get the
8383
weight.
84+
8485
Returns:
8586
The weight of a given hop.
8687
@@ -89,7 +90,7 @@ def get_weight(self, hop: Hop) -> float:
8990
without the sampling strategy having been trained.
9091
9192
"""
92-
if not (self._pred_degs and self._obj_degs and self._neighbor_counts):
93+
if self._pred_degs or self._obj_degs or self._neighbor_counts:
9394
raise ValueError(
9495
"You must call the `fit(kg)` method before get the weight of"
9596
+ " a hop."

0 commit comments

Comments
 (0)