fixed viterbi comparison issue