Skip to content

Commit

Permalink
Merge pull request nltk#1813 from nltk/alvations-patch-wordnet
Browse files Browse the repository at this point in the history
Ensure self is its own lowest subsumer when needed
  • Loading branch information
stevenbird authored Aug 16, 2017
2 parents e45d45c + 938fe57 commit b66e087
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion nltk/corpus/reader/wordnet.py
Original file line number Diff line number Diff line change
Expand Up @@ -905,7 +905,7 @@ def wup_similarity(self, other, verbose=False, simulate_root=True):
if len(subsumers) == 0:
return None

subsumer = subsumers[0]
subsumer = self if self in subsumers else subsumers[0]

# Get the longest path from the LCS to the root,
# including a correction:
Expand Down

0 comments on commit b66e087

Please sign in to comment.