I have been scratching my head try to understand how to use the GMM model returned by the opencv grabcut function(python API), the GMM models returned are 2* 64 elements tuple which I assume contains both the mean and variance information but I don't know how to apply it to a pixel that contains 3 color channel to predict how likely it belongs to the foreground or the background. I didn't manage to find any example code that does anything with the GMM models returned by the grabcut function.
Alternatively, I understand that I can use EM.predict to obtain the possibilities if I build the graph and train background/foreground using EM. But I want to be able to use grabcut the way it's written.
Any help will be greatly appreciated!