我正在测试几种机器学习算法的实现,检查它们是否能够像论文中描述的那样高效工作,并确保它们能够为我们的统计 NLP(自然语言处理)平台提供强大的功能。
你们能给我展示一些测试算法实现的方法吗?
1)哪些方面?
2)如何?
3)我必须遵循一些基本步骤吗?
4)使用不同的编程语言时是否必须考虑多样性的具体情况?
5)我必须了解算法吗?我的意思是,如果我真的知道算法是什么以及它是如何工作的,它会提供任何帮助吗?
基本上,我们使用 C 或 C++ 来实现算法,我们的工作环境是 Linux/Unix。我们的测试方法只关注黑盒测试和测试函数的输入/输出。我渴望改进它们,但我现在没有更好的想法......
太棒了!哈哈
I am working on testing several Machine Learning algorithm implementations, checking whether they can work as efficient as described in the papers and making sure they could offer a great power to our statistic NLP (Natural Language Processing) platform.
Could u guys show me some methods for testing an algorithm implementation?
1)What aspects?
2)How?
3)Do I have to follow some basic steps?
4)Do I have to consider diversity specific situations when using different programming languages?
5)Do I have to understand the algorithm? I mean, does it offer any help if I really know what the algorithm is and how it works?
Basically, we r using C or C++ to implement the algorithm and our working env is Linux/Unix. Our testing methods only focus on black box testing and testing input/output of functions. I am eager to improve them but I dont have any better idea now...
Great Thx!! LOL
发布评论
评论(1)
对于许多机器学习和统计分类任务,衡量质量的标准指标是精度和召回率。大多数已发布的算法都会对这些指标做出某种声明,或者您可以自己实现它们并运行这些测试。这应该可以很好地衡量您可以期望的质量。
当您谈论算法的效率时,这通常是关于算法的时间或空间性能的一些陈述,根据其输入的大小或复杂性(通常以 大 O 表示法)。大多数已发布的算法都会报告算法的时间和空间特征的上限。您可以将其用作比较指标,尽管您需要了解一些有关计算复杂性的知识,以确保您没有欺骗自己。您还可以通过手动检查程序代码来获取此信息,但这可能没有必要,因为此信息几乎总是与算法一起发布。
最后,理解算法总是一个好主意。它使您更容易知道作为该算法的用户需要做什么,以确保您获得最佳结果(并且确实知道您获得的结果是否合理),并且它将使您能够应用质量措施,例如我在本答案第一段中建议的措施。
For many machine learning and statistical classification tasks, the standard metric for measuring quality is Precision and Recall. Most published algorithms will make some kind of claim about these metrics, or you could implement them and run these tests yourself. This should provide a good indicative measure of the quality you can expect.
When you talk about efficiency of an algorithm, this is usually some statement about the time or space performance of an algorithm in terms of the size or complexity of its input (often expressed in Big O notation). Most published algorithms will report an upper bound on the time and space characteristics of the algorithm. You can use that as a comparative indicator, although you need to know a little bit about computational complexity in order to make sure you're not fooling yourself. You could also possibly derive this information from manual inspection of program code, but it's probably not necessary, because this information is almost always published along with the algorithm.
Finally, understanding the algorithm is always a good idea. It makes it easier to know what you need to do as a user of that algorithm to ensure you're getting the best possible results (and indeed to know whether the results you are getting are sensible or not), and it will allow you to apply quality measures such as those I suggested in the first paragraph of this answer.