{'fraction_non_alphanumeric': 0.012975778546712802, 'fraction_numerical': 0.0, 'mean_word_length': 5.687861271676301, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Efficient parameter training for hidden Markov models using posterior sampling training and Viterbi training

Hidden Markov models are widely employed by numerous Bioinformatics programs used today. Many existing Bioinformatics applications risk becoming obsolete unless they can be readily adapted to new data sets, for example by incorporating algorithms for automatic parameter training. We present a new method for training the parameters of hidden Markov models using sampled state paths. As these state paths are sampled from the posterior distribution, we call our new training algorithm posterior sampling training. We also introduce a computationally efficient, linear-memory algorithm for posterior sampling training. In addition, we introduce the first linear-memory algorithm for Viterbi training. We evaluate posterior sampling training by comparing it to Viterbi training and Baum-Welch training for a hidden Markov model and find that posterior sampling training outperforms Baum-Welch training in terms of performance and computationally efficiency and that it is significantly more robust than the commonly used method of Viterbi training.