Modified viterbi alignment script