finished viterbi search and back trace, did not test