NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Hash-Grams: Faster N-Gram Features for Classification and Malware Detection

Edward Raff, Charles Nicholas

Abstract

N-grams have long been used as features for classification problems, and their distribution often allows selection of the top-k occurring n-grams as a reliable first-pass to feature selection. However, this top-k selection can be a performance bottleneck, especially when dealing with massive item sets and corpora. In this work we introduce Hash-Grams, an approach to perform top-k feature mining for classification problems. We show that the Hash-Gram approach can be up to three orders of magnitude faster than exact top-k selection algorithms. Using a malware corpus of over 2 TB in size, we show how Hash-Grams retain comparable classification accuracy, while dramatically reducing computational requirements.
BibTeX
@inproceedings{raff2018hash,
  author = {Edward Raff and Charles Nicholas},
  title = {{Hash-Grams: Faster N-Gram Features for Classification and Malware Detection}},
  booktitle = {DocEng},
  year = {2018},
  doi = {10.1145/3209280.3229085},
}

Loading related content...

Figure