模式识别算法 [英] Pattern recognition algorithms

查看:133
本文介绍了模式识别算法的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在过去我不得不开发一个程序,它充当了规则评估。你有一个前提和一些consecuents(动作),所以如果前因evaled为真,其中执行的操作。

In the past I had to develop a program which acted as a rule evaluator. You had an antecedent and some consecuents (actions) so if the antecedent evaled to true the actions where performed.

当时我用了一个修改版本的 Rete算法(有三个版本RETE只有第一个公职)为前提的模式匹配。我们谈论的是一个大的系统,在这里,每个规则的运作和一些运营商在若干规则重复的万元。

At that time I used a modified version of the RETE algorithm (there are three versions of RETE only the first being public) for the antecedent pattern matching. We're talking about a big system here with million of operations per rule and some operators "repeated" in several rules.

这是可能我得在其他语言一遍实现,而且,即使我经历了RETE,没有人知道其他模式匹配算法?任何建议或我应该继续使用RETE?

It's possible I'll have to implement it all over again in other language and, even though I'm experienced in RETE, does anyone know of other pattern matching algorithms? Any suggestions or should I keep using RETE?

推荐答案

该TREAT算法是类似的Rete,但不会记录部分匹配。其结果是,它可能会使用比RETE在某些情况下存储器更少。另外,如果你修改显著一些已知的事实,则治可以更快,因为你没有花时间撤消。

The TREAT algorithm is similar to RETE, but doesn't record partial matches. As a result, it may use less memory than RETE in certain situations. Also, if you modify a significant number of the known facts, then TREAT can be much faster because you don't have to spend time on retractions.

还有 RETE * 这RETE和治疗之间的平衡通过节省一些连接节点的状态取决于你要多少内存来使用。所以,你还是省点断言时间,而且还可以获得内存和回缩节省时间取决于您如何调整系统。

There's also RETE* which balances between RETE and TREAT by saving some join node state depending on how much memory you want to use. So you still save some assertion time, but also get memory and retraction time savings depending on how you tune your system.

您可能也想看看长期期权,它采用了懒惰的评价方案,并结合双方RETE和治疗。

You may also want to check out LEAPS, which uses a lazy evaluation scheme and incorporates elements of both RETE and TREAT.

我只有亲身经历RETE,但似乎RETE *或长期期权是更好的,更灵活的选择。

I only have personal experience with RETE, but it seems like RETE* or LEAPS are the better, more flexible choices.

这篇关于模式识别算法的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆