A software utility for clustering using Expectation Maximization Estimation
The project requires a few open-source libraries:
OpenCV (v3.1) (OpenCV is used for its convinient matrix structure. The built-in EM function in openCV is not used here.)
Eigen (v3.3.4)
You can find a detailed tutorial on setting up OpenCV within your Visual Studio environment here: https://www.deciphertechnic.com/install-opencv-with-visual-studio/
Inside Properties of your project,
-
Go to C/C++ > General. Copy the path to include folder of opencv and paste it inside Additional Include Directories. The path will look similar to C:\opencv\build\include. Then, click Apply.
-
Go to linker > General. Copy the path to folder containing opencv lib files and paste it inside Additional Library Directories. The path will look similar to C:\opencv\build\x64\vc14\lib. Then, click Apply.
-
Go to linker > Input > Additional Dependencies. Add the following lib file: opencv_world310d.lib
To run the program, you can use the EMClassification.cpp file. The program finds initial clusters using k-means and then computes the first approximation of the gaussian parameters. Then the program iteratively computes the E-step and the M-step to find better approximations for the clusters.
Free-to-use (MIT), please use at your own risk