码迷,mamicode.com
首页 > 其他好文 > 详细

多示例学习 multiple instance learning (MIL)

时间:2016-11-17 00:28:45      阅读:356      评论:0      收藏:0      [点我收藏+]

标签:ati   ext   native   span   library   eve   nbsp   存在   之间   

多示例学习:包(bags) 和 示例 (instance).

包是由多个示例组成的,举个例子,在图像分类中,一张图片就是一个包,图片分割出的patches就是示例。在多示例学习中,包带有类别标签而示例不带类别标签,最终的目的是给出对新的包的类别预测。

多示例学习是弱监督学习中的一个popular的方法。用于训练分类器的instance是没有类别标记的,但是bags却是有类别标记的,这一点与以往所有框架均不甚相同。

多示例学习中的规则:如果一个bag 里面存在至少一个instance被分类器判定标签为+(或者1)的示例,则该包为正包;如果一个bag里面所有的instance都被分类器判定标签为-,则该包为负包。

问题的实际应用:做检测问题,标记训练图片样本的时候需要给出一个矩形框指明目标的位置,有可能标的不够准确,导致不同的样本之间对不齐,这时候可以将标记的矩形框做一些局部扰动得到一些新的矩形框,将它们一起看成一个bag,其中总有一个是最佳的正样本,也就是标记为正。而取一张没有目标的图片,作为负样本包,无论在里面怎么截取图片,都是负样本。

解决这个问题的方法:迭代优化(alternative optimization)。分为两步:监督学习,标记更新

首先假设已知所有样本的标记,使用一个监督学习的方法得到一个分类模型;用这个模型对每个训练样本进行预测,更新它们的标记。------以上是一个过程

之后再根据新得到的标记样本重新训练分类器,再对每个训练样本进行预测;再训练分类器,再预测标记;再训练,再预测。。。。。。

需要注意的地方:

1)训练监督学习模型的时候,只从正样本包里挑选被预测的“最像正确”(也就是分类得到最高)的那一个,正样本包里面其他的样本,不管预测出来的是正还是负的都不要了。这是因为,其中多示例的问题也可以描述为,正样本包里面“最正确”的一个样本标记是正的,跟其他样本无关。所以,这种选择策略恰恰是符合问题定义的。

2)如果负样本足够多的话,可以只挑选每个负样本包里面被预测“最像正确”的一个样本作为负样本进行训练,这样的负样本也叫做hard sample 或者 most violated sample。实践中,它们对于模型快速收敛是最有效的。

流程图:

输入:数据矩阵

MILL (MIL Library) is an open-source toolkit for multiple instance learning algorithms written in Matlab. Multiple-instance learning (MIL) is a form of semi-supervised learning where there is only incomplete knowledge on the labels of the training data. Specifically, instances in MIL are grouped into a set of bags. The labels of the bags are provided, but the labels of instances in the bags are unknown. However, a bag is labeled positive if at least one instance in the bag is positive, and a bag is negative if all the instances in it are negative. MIL algorithms attempt to learn a classification function that can predict the labels of bags and/or instances in the testing data. The applications of MIL include molecule activity prediction (分子活动预测), text categorization(文本分类), image classification and retrieval (图像分类和检索), etc. 

 

多示例学习 multiple instance learning (MIL)

标签:ati   ext   native   span   library   eve   nbsp   存在   之间   

原文地址:http://www.cnblogs.com/rong86/p/6071748.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!