-
Notifications
You must be signed in to change notification settings - Fork 12
Description
Hi,
we ran the following set of test data through the original python library as well as the Java port where a and b are the two strings, WRatio is the weighted ratio and PRatio is the partial ratio:
`[
{
"a": "Foo",
"b": "Bar",
"WRatio": 0,
"PRatio": 0
},
{
"a": "Foo",
"b": "Foo",
"WRatio": 100,
"PRatio": 100
},
{
"a": "Foo",
"b": "Fox",
"WRatio": 67,
"PRatio": 67
},
{
"a": "Foo",
"b": "FooFoo",
"WRatio": 90,
"PRatio": 100
},
{
"a": "차량 내부 기후 제어 구역",
"b": "실내 기후",
"WRatio": 86,
"PRatio": 80
},
{
"a": "Navigation",
"b": "Mavi",
"WRatio": 68,
"PRatio": 75
},
{
"a": "Navigation",
"b": "Nav",
"WRatio": 90,
"PRatio": 100
},
{
"a": "Navigation",
"b": "Na",
"WRatio": 90,
"PRatio": 100
},
{
"a": "실내 기후",
"b": "차량 내부 기후 제어 구역",
"WRatio": 86,
"PRatio": 80
}
]`
Both the Java and Python implementation produce these exact results, however this library produces different results:
PARTIAL
Result: 0, Expected: 0
Result: 0, Expected: 100
Result: 80, Expected: 67
Result: 0, Expected: 100
Result: 0, Expected: 80
Result: 0, Expected: 75
Result: 80, Expected: 100
Result: 66, Expected: 100
Result: 0, Expected: 80
WEIGTHED
Result: 50, Expected: 0
Result: 100, Expected: 100
Result: 83, Expected: 67
Result: 66, Expected: 90
Result: 56, Expected: 86
Result: 50, Expected: 68
Result: 72, Expected: 90
Result: 59, Expected: 90
Result: 56, Expected: 86
Any idea why this library produces different results?