3.66667

3.7 | 4 ratings Rate this file 166 downloads (last 30 days) File Size: 31.77 KB File ID: #7055

Multivariate Gaussian Mixture Model Optimization by Cross Entropy

by Sebastien Paris

 

04 Mar 2005 (Updated 07 Jul 2010)

Code covered by the BSD License  

Stochastic multi-extremum optimization.

Download Now | Watch this File

File Information
Description

Fit a multivariate gaussian mixture by a cross-entropy method. Cross-Entropy is a powerfull tool to achieve stochastic multi-extremum optimization.

Please visit http://iew3.technion.ac.il/CE/ for more informations

i) Please compile mex-files by the mexme_ce_gauss.m (if compiler is not setup, run mex -setup before.

ii) Run the program demo test_ce_mvgm.m

MATLAB release MATLAB 6.5 (R13)
Other requirements A C compiler
Zip File Content  
Other Files
ce_mvgm.m,
corr2cov.c,
cov2corr.c,
dirichlet_mle.c,
dirirnd.c,
license.txt,
loglike_mvgm.c,
mexme_ce_gauss.m,
mvgmmpdf.c,
ndellipse.c,
randnt.c,
sample_gaussian_mixture.m,
sample_mvgm.c,
test_ce_mvgm.m
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Comments and Ratings (12)
16 Oct 2005 Michael Boedigheimer

Includes an optional animated display of the current solution as it converges, which is fun.
One nice feature is that it can estimate the number of guassian mixtures that are present. Given the correct starting number, it did better than the EM method I used (at least for the single challenging case I looked at).
Offers a lot of control of the starting and boundary conditions, which may be important in some applications.
Mostly written in c, with windows dll. means its less portable. Even so, it is still slow.

01 Dec 2005 George Uameres

What fun!
nice way to learn about gaussian mixture models.

04 Dec 2006 feng shigang  
04 Dec 2006 feng shigang  
13 Mar 2010 Omid Aghazadeh

Perhaps a revision is required for higher verions of matlab. Could not run the code on R2009b. Passing a 3XK matrix as input, I get
??? Index exceeds matrix dimensions.

Error in ==> ce_mvgm at 314
    Rmax(indice1) = Ra(indice1)/9 + 2*Ra(indice1)/9;
....
Ra is of dimension 1X3 and indice1 has indexes up to 9.

13 Mar 2010 Omid Aghazadeh

Solved that one. (Needed to compile mex files!)
Now, I get NaNs!
t = 2, current sol = NaN, global sol = Inf, d = 0
t = 3, current sol = NaN, global sol = Inf, d = 0
t = 4, current sol = NaN, global sol = Inf, d = 0

14 Mar 2010 Sebastien Paris

I think randnt is not well compiled. Did you had the correct option

mex -DranSHR3 randnt.c

or

mex -DranKISS randnt.c

?
 

05 Jul 2010 Geoffrey Lewen

mex files compile without error and test_ce_mvgm runs without error but hangs, requiring force-kill of Matlab 2010a to recover. Using debugger, so far, sample_gaussian_mixture.m is the routine hanging....

05 Jul 2010 Sebastien Paris

Geoffrey, please give you exact plateform, i.e., OS, CPU, Compiler and so on ... Thanks you

05 Jul 2010 Geoffrey Lewen

Microsoft Windows XP Version 5.1 (Build 2600: SP2)
Intel Core(TM)2 Duo CPU T7300@2.00GHz
2.97GB RAM
MATLAB Version 7.10.0.499 (R2010a)
Java VM Version: Java 1.6.0_12-b04
Sun Microsystems Inc. Java HotSpot(TM) Client VM mixed mode

* MATLAB Compiler Version 4.13 (R2010a

Thank You!

06 Jul 2010 Sebastien Paris

and your C compiler ? LCC, MSVC ?

(mex -setup)

06 Jul 2010 Geoffrey Lewen

Sorry---compiler is LCC.

Please login to add a comment or rating.
Updates
01 Aug 2005

V1.1 : -add extra parameters in the main function
       -mvgmmrnd & loglikelihood handle a more general synthax

29 Sep 2005

Missing randnt mex file in the Zip distribution.....

16 Aug 2006

V 1.2 -Add a better procedure to estimate weight's mixture
      -Fix some small bugss
      -Add pdf display

16 Aug 2006

V1.3 Missing files

06 Jun 2008

v1.4 - Update randnt.c with a new uniform generator
      - Improve help sections
      - Change some fuction' names

14 Mar 2010

-Add mexme_ce_gauss.m to compile mex-files

07 Jul 2010

-Correct a problem with LCC compiler for dirirnd.c
-sample_mvgm.c compatible with GCC compiler

Tag Activity for this File
Tag Applied By Date/Time
optimization Sebastien Paris 22 Oct 2008 07:42:39
cross entropy Sebastien Paris 22 Oct 2008 07:42:39
gaussian Sebastien Paris 22 Oct 2008 07:42:39
multivariate Sebastien Paris 22 Oct 2008 07:42:39
stochastic optimization Sebastien Paris 07 Jul 2010 09:27:05
multivariate gaussian mixture Sebastien Paris 07 Jul 2010 09:27:05

Contact us at files@mathworks.com