【问题标题】:FIND-S Algorithm - simple questionFIND-S 算法 - 简单问题
【发布时间】:2011-08-11 01:31:36
【问题描述】:

FIND-S 算法可能是最简单的机器学习算法之一。但是,我在那里找不到很多示例。只是机器学习中总是使用的标准“晴天、下雨、打球”示例。请有人帮我解决这个应用程序(它是机器学习中过去的考试问题)。

假设的形式为a <= x <= bc <= y <= d,其中xyx,y 平面中的点,cd 是任意整数。基本上,这些假设定义了x,y 空间中的矩形。

这些是训练示例,其中- 是一个负例,+ 是一个正例,并且这对是x,y 坐标:

 + 4, 4
 + 5, 3 
 + 6, 5 
 - 1, 3 
 - 2, 6 
 - 5, 1 
 - 5, 8 
 - 9, 4

我要做的就是将 FIND-S 应用到这个例子中!一定很简单!一些提示或解决方案都会很棒。

谢谢。

【问题讨论】:

    标签: artificial-intelligence machine-learning


    【解决方案1】:

    Find-S 寻求适合所有正例的最严格(即最“具体”)的假设(忽略负例)。

    在您的情况下,有一个明显的图形解释:“找到包含所有 '+' 坐标的最小矩形”...

    ...这将是 a=4、b=6、c=3、d=5。

    这样做的算法是这样的:

    Define a hypothesis rectangle h[a,b,c,d], and initialise it to [-,-,-,-]
    for each + example e {
        if e is not within h {
            enlarge h to be just big enough to hold e (and all previous e's)
        } else { do nothing: h already contains e }
    }
    

    如果我们使用您的训练集逐步完成此操作,我们会得到:

     0. h = [-,-,-,-] // initial value
     1. h = [4,4,4,4] // (4,4) is not in h: change h so it just contains (4,4)
     2. h = [4,5,3,4] // (5,3) is not in h, so enlarge h to fit (4,4) and (5,3)
     3. h = [4,6,3,5] // (6,5) is not in h, so enlarge again
     4. // no more positive examples left, so we're done.
    

    【讨论】:

    • 谢谢!很高兴我能帮上忙。
    • 什么是 a、b、c 和 d?
    • 它在上面的问题中说:“假设的形式是 a
    猜你喜欢
    • 1970-01-01
    • 2021-08-23
    • 2010-11-14
    • 2011-03-13
    • 2010-12-10
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多