Be the first to rate this file! 89 Downloads (last 30 days) File Size: 1.46 MB File ID: #33541
image thumbnail

Fast K-means clustering

by Sebastien PARIS

 

31 Oct 2011 (Updated 09 Nov 2012)

Fast mex K-means clustering algorithm with possibility of K-mean++ initialization.

| Watch this File

File Information
Description

Fast mex K-means clustering algorithm with possibility of K-mean++ initialization
(mex-interface modified from the original yael package https://gforge.inria.fr/projects/yael)

- Accept single/double precision input
- Support of BLAS/OpenMP for multi-core computation

Please run mexme_yael_kmeans.m to compile mex-files (be sure that mex -setup have been done at least one)

Run demo "test_yael_kmeans.m"

Required Products MATLAB
MATLAB release MATLAB 7.9 (R2009b)
Other requirements For a full usage, a OpenMP C compiler compliant such MSCV/Intel compiler/GCC. Shoud work with LCC but without OpenMP support.
Tags for This File  
Everyone's Tags
image processing, mathematics, statistics
Tags I've Applied
Add New Tags Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (8)
26 Dec 2012 Sebastien PARIS

Sepehr,
Can you indicate what is your OS, CPU and compiler used ? Did you recompile mex-files also ?

26 Dec 2012 Sepehr Farhand

Matlab crashes w/ segmentation fault. I guess you have a loose pointer somewhere. "Segmentation violation detected"

02 Oct 2012 Sebastien PARIS

Leila ...

It supports of course 3d vectors or more ...

03 Jul 2012 leila

Does the code support 3d data?

29 Jun 2012 Sebastien PARIS

Thank you for reporting ...
The update with correction will be published soon.

28 Jun 2012 Bonolo

on the mac, need to change lib= '-lmwblas'; to libblas= '-lmwblas';

otherwise compiles fine.

30 May 2012 Sebastien PARIS

Vladimir,

Did you compile mex-files first ?

Please run mexme_yael_kmeans.m to compile mex-files (be sure that mex -setup have been done at least one)

30 May 2012 Vladimir

Using MSVC++ 2010 compiler, sample_mvgm throws an error when called in test_yael_kmeans:
"mu must be (d x 1 x M x n1 x ... x nl)"
where
mu = cat(3 , [-2.5 ; -3] , [0 ; 0] ,[ 5 ; 5]); %(d x 1 x M)

Updates
01 Nov 2011

- Add online help, minor changes

04 Nov 2011

- Minor changes
- Add spiral clustering example in the test file

24 Mar 2012

-Correct a bug in randperm

29 Jun 2012

-Correct a bug in mexme_yael_kmeans.m for Linux/Mac Os

27 Sep 2012

- Fix a bug in ndellipse introduced in the last update

09 Nov 2012

- Fix compilation issue in mexme_yael_kmeans
- Include both mexw32 & mexw64 files in two separate files (unzip them in local dir in case of problem)

Contact us