Perl code to run HMM + restricted Viterbi on IceMorph data