multithread gmm