Skip to content

Commit

Permalink
ensure that matchop query is floating-point format (not scientific no…
Browse files Browse the repository at this point in the history
…tation, which breaks the parser)
  • Loading branch information
seanmacavaney authored Aug 21, 2024
1 parent 89ed210 commit 7a156cc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pyterrier/terrier/retriever.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def _matchop_tok(t, w):
encoded = base64.b64encode(t.encode('utf-8')).decode("utf-8")
t = f'#base64({encoded})'
if w != 1:
t = f'#combine:0={w}({t})'
t = f'#combine:0={w:f}({t})'
return t
return ' '.join([ _matchop_tok(t, w) for (t,w) in query_toks.items() ])

Expand Down

0 comments on commit 7a156cc

Please sign in to comment.