From: Bo Li Date: Fri, 12 Aug 2011 18:13:49 +0000 (-0500) Subject: fix one bug will lead using not the last theta value estimates X-Git-Url: https://git.donarmstrong.com/?p=rsem.git;a=commitdiff_plain;h=534e12beacb83144d7d305d5cabfc8a9272b1a75 fix one bug will lead using not the last theta value estimates --- diff --git a/EM.cpp b/EM.cpp index 15dd117..5f9b8c0 100644 --- a/EM.cpp +++ b/EM.cpp @@ -571,6 +571,7 @@ void EM() { //calculate expected weights and counts using learned parameters updateModel = false; calcExpectedWeights = true; + for (int i = 0; i <= M; i++) probv[i] = theta[i]; for (int i = 0; i < nThreads; i++) { rc = pthread_create(&threads[i], &attr, E_STEP, (void*)(&fparams[i])); if (rc != 0) { fprintf(stderr, "Cannot create thread %d when calculate expected weights! (numbered from 0)\n", i); exit(-1); }