Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error while running fuzzywuzzy/fuzz.py

I have a program that uses fuzzywuzzy to match to csvs and find any strings that might be duplicates or very similar. When I compare my two files, fuzzywuzzy raises the following error:

WARNING:root:Applied processor reduces input query to empty string all comparisons will have score 0. [Query:'+']

Anyone have any idea what cause that error to come up?

like image 749
Ecanales Avatar asked Apr 29 '26 04:04

Ecanales


1 Answers

The error comes from process.extractOne().

Fuzzywuzzy does some cleaning of the queries you give it, including case folding and replacing non-letters and non-numbers with white space.

Your query only contains a plus sign, which is replaced by white space, leaving an empty string, which cannot be fuzzy matched against. That causes the error.

like image 133
Monozygotic Avatar answered Apr 30 '26 19:04

Monozygotic



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!