{'fraction_non_alphanumeric': 0.030114226375908618, 'fraction_numerical': 0.005192107995846314, 'mean_word_length': 5.025, '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}}
Learning anomalous features via sparse coding using matrix norms

Our goal is to find anomalous features in a dataset using the sparse coding concept of dictionary learning. Rather than using the averaged column ℓ2-norm for the dictionary update as is typically done in sparse coding, we explore using three matrix norms: ∥·∥1, ∥·∥2, and ∥·∥∞. Minimizing the matrix norms represents minimizing a maximum deviation in the reconstruction error rather than an average deviation, hopefully allowing us to find features that contribute significantly but infrequently to sample training points. We find that while solving for the dictionaries using matrix norm minimization takes longer to compute, all three methods are able to recover a known basis from a simple set of training data. In addition, the ∥·∥1 matrix norm is able to recover a known anomalous feature in the training data that the other norms (including the standard averaged ℓ2-norm) are unable to find.