小编Naz*_*nko的帖子

阈值滤波器C#的模糊匹配

我需要实现某种形式:

string textToSearch = "Extreme Golf: The Showdown";
string textToSearchFor = "Golf Extreme Showdown";
int fuzzyMatchScoreThreshold = 80; // One a 0 to 100 scale
bool searchSuccessful = IsFuzzyMatch(textToSearch, textToSearchFor, fuzzyMatchScoreThreshold);
if (searchSuccessful == true)
{
    -- we have a match.
}
Run Code Online (Sandbox Code Playgroud)

这是用C#编写的函数存根:

public bool IsFuzzyMatch (string textToSearch, string textToSearchFor, int fuzzyMatchScoreThreshold)
{
   bool isMatch = false;
   // do fuzzy logic here and set isMatch to true if successful match.
   return isMatch;
}
Run Code Online (Sandbox Code Playgroud)

但我不知道如何在IsFuzzyMatch方法中实现逻辑.有任何想法吗?也许为此目的有一个现成的解决方案?

c# fuzzy-search fuzzy-logic

8
推荐指数
2
解决办法
6376
查看次数

标签 统计

c# ×1

fuzzy-logic ×1

fuzzy-search ×1