Remove redundant title_match entries
This commit is contained in:
@@ -460,15 +460,11 @@ class DeeLogin:
|
||||
candidates = []
|
||||
|
||||
for cand in candidates:
|
||||
title_match_1 = max(
|
||||
_sim(spo_title, dz_json.get('title', '')),
|
||||
_sim(spo_title, dz_json.get('title_short', ''))
|
||||
)
|
||||
title_match_2 = max(
|
||||
title_match = max(
|
||||
_sim(_remove_parentheses(spo_title), _remove_parentheses(dz_json.get('title', ''))),
|
||||
_sim(_remove_parentheses(spo_title), _remove_parentheses(dz_json.get('title_short', '')))
|
||||
)
|
||||
if max(title_match_1, title_match_2) < 0.90:
|
||||
if title_match < 0.90:
|
||||
continue
|
||||
c_id = cand.get('id')
|
||||
if not c_id:
|
||||
|
||||
Reference in New Issue
Block a user