Update Lda implementation.