EM算法概念
EM算法是一种非常经典的alternative optimizing算法。alternative optimizing的思想就是对于一个最优化问题,可以计算分为两步或者参数分为两个,就可以随机任意的选择一个起始值或位置,固定一个参数A,以另一个参数B进行优化,然后固定参数B,以参数A进行优化,直到收敛未知。前面博文中所讲述的K-means也就这样的一个过程,或者meanshift均值漂移也是这样的一个思想。今天学习的一个算法也是这样一个概念。这里依然做一个入门级的概念理解指导,不做原理性的深入,后续等用到时在进行深入学习。参考维基百科。
In statistics, an expectation–maximization (EM) algorithm is an iterative method for finding maximum likelihood or maximum a posteriori (MAP) estimates of parameters in statistical models, where the model depends on unobserved latent variables. The EM iteration alternates between performing an expectation (E) step, which creates a function for the expectation of the log-likelihood evaluated using the current estimate for the parameters, and a maximization (M) step, which computes parameters maximizing the expected log-likelihood found on the E step. These parameter-estimates are then used to determine the distribution of the latent variables in the next E step.
上面讲述了EM算法的轮廓,EM算法是一个用来寻找model参数的最大似然估计或最大后验估计的迭代方法,而这个model依赖于没有观测的潜在变量。所以,EM算法采用alternative optimizing的思想,首先执行expectation 步,利用当前的参数构建最大似然函数(log),然后执行maximization 步,生成新的参数,就这样不断地交替计算优化迭代下去,直到收敛为止。
The EM algorithm is used to find (locally) maximum likelihood parameters of a statistical model in cases where the equations cannot be solved directly. Typically these models involve latent variables in addition to unknown parameters and known data observations. That is, either there are missing values among the data, or the model can be formulated more simply by assuming the existence of additional unobserved data points. For example, a mixture model can be described more simply by assuming that each observed data point has a corresponding unobserved data point, or latent variable, specifying the mixture component that each data point belongs to.
Finding a maximum likelihood solution typically requires taking the derivatives of the likelihood function with respect to all the unknown values — viz. the parameters and the latent variables — and simultaneously solving the resulting equations. In statistical models with latent variables, this usually is not possible. Instead, the result is typically a set of interlocking equations in which the solution to the parameters requires the values of the latent variables and vice versa, but substituting one set of equations into the other produces an unsolvable equation.
The EM algorithm proceeds from the observation that the following is a way to solve these two sets of equations numerically. One can simply pick arbitrary values for one of the two sets of unknowns, use them to estimate the second set, then use these new values to find a better estimate of the first set, and then keep alternating between the two until the resulting values both converge to fixed points. It’s not obvious that this will work at all, but in fact it can be proven that in this particular context it does, and that the derivative of the likelihood is (arbitrarily close to) zero at that point, which in turn means that the point is either a maximum or a saddle point.[12] In general there may be multiple maxima, and there is no guarantee that the global maximum will be found. Some likelihoods also have singularities in them, i.e. nonsensical maxima. For example, one of the “solutions” that may be found by EM in a mixture model involves setting one of the components to have zero variance and the mean parameter for the same component to be equal to one of the data points.
EM算法通常用来找到无法直接解决的(局部的)最大似然参数。在最优化问题求解时,一个参数的解需要另一个潜在的变量值,而这个潜在变量的值则需要那一个参数的解,就这样交织在一起。这个时候最好的办法就是alternative
optimizing。这里对应的是EM算法。
EM算法可以任意的选择两个set中的一个,并给定任意的值,利用它们去估计第二个,然后用这个新的值去估计找到一个更好的第一个set的值,就这样交替的执行,直到结果收敛到某些固定的点为止。这个流程并不一定能很好地工作,但是在一些特别的上下文中可以证明它是可行的。只是很多时候可能是局部最优或者是到了马鞍点。
2015-8-28 艺少
EM算法概念的更多相关文章
- 简单理解EM算法Expectation Maximization
1.EM算法概念 EM 算法,全称 Expectation Maximization Algorithm.期望最大算法是一种迭代算法,用于含有隐变量(Hidden Variable)的概率参数模型的最 ...
- EM算法总结
EM算法总结 - The EM Algorithm EM是我一直想深入学习的算法之一,第一次听说是在NLP课中的HMM那一节,为了解决HMM的参数估计问题,使用了EM算法.在之后的MT中的词对齐中也用 ...
- 【EM算法】EM(转)
Jensen不等式 http://www.cnblogs.com/jerrylead/archive/2011/04/06/2006936.html 回顾优化理论中的一些概念.设f是定义域为实数的函数 ...
- 极大似然估计、贝叶斯估计、EM算法
参考文献:http://blog.csdn.net/zouxy09/article/details/8537620 极大似然估计 已知样本满足某种概率分布,但是其中具体的参数不清楚,极大似然估计估计就 ...
- EM算法原理
在聚类中我们经经常使用到EM算法(i.e. Estimation - Maximization)进行參数预计, 在该算法中我们通过函数的凹/凸性,在estimation和maximization两步中 ...
- 关于机器学习-EM算法新解
我希望自己能通俗地把它理解或者说明白,但是,EM这个问题感觉真的不太好用通俗的语言去说明白,因为它很简单,又很复杂.简单在于它的思想,简单在于其仅包含了两个步骤就能完成强大的功能,复杂在于它的数学推理 ...
- 猪猪的机器学习笔记(十四)EM算法
EM算法 作者:樱花猪 摘要: 本文为七月算法(julyedu.com)12月机器学习第十次次课在线笔记.EM算法全称为Expectation Maximization Algorithm,既最大 ...
- 从最大似然到EM算法浅解
从最大似然到EM算法浅解 zouxy09@qq.com http://blog.csdn.net/zouxy09 机器学习十大算法之中的一个:EM算法.能评得上十大之中的一个,让人听起来认为挺NB的. ...
- EM算法--第一篇
在统计计算中,最大期望(EM)算法是在概率(probabilistic)模型中寻找参数最大似然估计或者最大后验估计的算法,其中概率模型依赖于无法观测的隐藏变量(LatentVariable).最大期望 ...
随机推荐
- Python学习之--字符串的使用
一.大小写转换 1. 首字母大写:title(); 如下: 2. 大写转换:upper(),如 3.小写转换:lower(),如 二.合并(拼接)字符串:”+“ 1. 2. 三.制表符.换行 制表符 ...
- Educational Codeforces Round 64 部分题解
Educational Codeforces Round 64 部分题解 不更了不更了 CF1156D 0-1-Tree 有一棵树,边权都是0或1.定义点对\(x,y(x\neq y)\)合法当且仅当 ...
- fhq treap ------ luogu P3369 【模板】普通平衡树(Treap/SBT)
二次联通门 : LibreOJ #104. 普通平衡树 #include <cstdio> #include <iostream> #include <algorithm ...
- 13、SparkContext详解
一.SparkContext原理 1.图解 二.SparkContext源码 1.TaskScheduler创建 ###SparkContext.scala // Create and start t ...
- 洛谷P2827蚯蚓
题目 堆+模拟,还有一个小优化(优化后跟堆关系不大,而是类似于贪心). 如果不加优化的话,卡常可以卡到85. 思路是对于对每一秒进行模拟,用堆来维护动态的最大值,然后对于每个长度都加q的情况可以用一个 ...
- MySQL 获得 当前日期时间 函数
mysql> select now(); 输出 -- :: 例子 mysql> ), now(); +---------------------+----------+---------- ...
- [树链剖分]BZOJ3589动态树
题目描述 别忘了这是一棵动态树, 每时每刻都是动态的. 小明要求你在这棵树上维护两种事件 事件0: 这棵树长出了一些果子, 即某个子树中的每个节点都会长出K个果子. 事件1: 小明希望你求出几条树枝上 ...
- VirtualAlloc加载shellcode免杀一点记录
一个很好的学习网站 推荐一下: https://docs.microsoft.com/zh-cn/windows/win32/api/ 0x01 VirtualAlloc VirtualAlloc: ...
- Chapter One
spring-boot-starter-parent spring-boot-starter-parent是一个特殊的Starter,提供了Maven的默认配置,同时还提供了dependency-ma ...
- Cent0S 6.7直接在/etc/resolv.conf文件下修改DNS地址重启不生效问题【转】
CentOS 6.7/Linux下设置IP地址 1:临时修改: 1.1:修改IP地址 # ifconfig eth0 192.168.2.104 1.2:修改网关地址 # route add defa ...