arXiv:2610.39351cs.CROct 2026

Manuscript Offprint

arXiv:2610.39351

Measuring Duplication, Leakage, and Rendering Dependence in Malware-as-Image Benchmarks

Stefan Larson, Kevin Leach

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Stefan Larson and Kevin Leach

Vanderbilt University, Nashville, TN, USA

{stefan.larson, kevin.leach}@vanderbilt.edu

Keywords: Malware Classification, Image Classification, Byteplot Images, Dataset Duplication, Test-Train Leakage, Benchmark Evaluation.

Abstract: Classifying malware binaries rendered as images is a popular approach to malware family identification, and papers on the standard benchmarks for this task report accuracies of 97–99%. In this paper we audit ten of these benchmarks for near-duplicate images and test-train leakage, and retrain standard classifiers under naive and content-aware splits. Deduplicating by file hash, which is the standard practice, does not prevent leakage, because distinct binaries render to identical images. Deduplicating on image content reduces top-1 accuracy by up to 8 points and macro-F1 by up to 15 points on the released benchmarks we find leaky. The rendering step also adds duplication, since byteplots of the same binaries contain 19.7% near-duplicates where static feature vectors contain 2.2%, and changing the width at which bytes are wrapped into rows reduces accuracy by 20 to 33 points, although no byte changes. We recommend that content-level duplication and a non-image baseline be reported alongside accuracy.

1 INTRODUCTION

Representing malicious code (malware) as an image is a popular approach to malware family classification. A binary is the file of raw bytes that contains a compiled program, and it can be read as a stream of unsigned 8-bit values and wrapped into rows of fixed width, which produces a grayscale image known as a byteplot. These images are used for family classification: a malware family is a group of programs derived from one code base, released as many variants by recompiling it, reconfiguring it, or running it through an obfuscator (a tool that rewrites a program so that its code differs but its behavior does not).

Nataraj et al. (2011) observed that programs in the same family produce visually similar textures under the byteplot encoding, and reported 98.08% accuracy across 25 families using GIST descriptors and a k-NN classifier. A large body of work has followed, and several benchmarks built to support it are now standard, including MaleVis (Bozkir et al., 2019), Dumpware10 (Bozkir et al., 2021), Virus-MNIST (Noever and Miller Noever, 2021), MalNet-Image (Freitas et al., 2022), AndroDex (Aurangzeb et al., 2024), MalVis (Makkawy et al., 2025) and MaleX (Mohammed et al., 2021). Papers that train CNN and Vision Transformer models on these benchmarks rou-

tinely report accuracies in the 97–99% range, and a recent survey of more than 100 papers in the area (Brosolo et al., 2025a) and a systematization of the same literature (Brosolo et al., 2024) both report this range.

Despite this volume of work, the quality of these benchmarks has received little scrutiny. Duplication is one concern, since the programs in a malware family are variants of a common program and their shared code produces identical or near-identical images. The rendering is a second concern, since the width at which bytes are wrapped into rows is an arbitrary choice by the benchmark creators, and whether a model's accuracy depends on that choice has not been tested.

Leakage through duplicates is documented across machine-learning-based science (Kapoor and Narayanan, 2023), and it is present even in canonical vision benchmarks, where 3.3% of CIFAR-10 and 10% of CIFAR-100 test images have a near-duplicate in training (Barz and Denzler, 2020). The same defect is measured in document classification (Larson et al., 2023, 2026), face recognition (Wu et al., 2024), license plate recognition (Laroca et al., 2023) and open-domain question answering (Lewis et al., 2021), and most of the studies that report accuracy find that models score lower on test data that does not have a counterpart in training. Studies of Android malware datasets of extracted features report mixed results on both effects (Pendlebury et al., 2019; Zhao et al., 2021), and whether either holds for the malware-as-image benchmarks has not been measured.

In this paper, we measure duplicate content and test-train overlap in ten malware-as-image benchmarks and quantify the effect of both on reported accuracy. We identify duplicates by the decoded pixels of each image, because benchmark creators deduplicate by the hash of the program file, and two different files can render to the same image. On MalNet-Tiny, whose authors deduplicated by file hash, 14.9% of the test images are pixel-identical to a training image. We then build deduplicated, family-grouped splits and retrain standard classifiers on them, and we examine the rendering step itself, both as a source of duplication that the underlying corpus does not contain and as a choice on which the trained model turns out to depend. We make our audit code, deduplicated splits and per-run results publicly available at https://github.com/gxlarson/malware-image-audit.

This paper is a benchmark audit, and we do not propose a new model, training procedure or dataset. Our contribution is to measure data quality inside the image benchmarks themselves and to quantify its effect on reported accuracy. This type of paper is in the tradition of prior work that has revealed similar problems in computer vision (Barz and Denzler, 2020; Radenović et al., 2018; Northcutt et al., 2021), NLP (Lewis et al., 2021) and document understanding (Larson et al., 2023, 2026) benchmarks.

To summarize, the main contributions of this paper are:

  1. We audit ten malware-as-image benchmarks, finding duplication rates from 0 to 35.7% and test-set leakage as high as 50.6%, and show that deduplicating by file hash, which is the standard practice, does not remove the leakage, since distinct files can contain identical code and render to identical images. On MalNet-Tiny, file-hash deduplication does not remove any images, so it does not recover any of the 8.44-point drop in accuracy that we measure under content-aware deduplication.

  2. We construct content-aware, family-grouped splits and retrain three architectures on the seven benchmarks small enough for us to train on repeatedly, and find that accuracy drops by 3.7 to 10.5 percentage points on five of them, while the drop on the other two is not significant. A training set enlarged with further copies of its own images is no more accurate, so the drop comes from test images that have a copy in training and not from

the smaller training set.

  1. We measure the contribution of the image encoding itself on the two corpora where this measurement is possible. MOTIF provides gold labels, raw binaries and static features together. MOTIF's feature vectors contain 2.2% near-duplicates and do not lose accuracy under deduplication, while our byteplots of the same samples contain 19.7% and lose 10.52 ± 2.23 points. Dumpware10 provides the same binaries at four byteplot widths, and training at one width and testing at another reduces accuracy by 20.53 ± 2.71 points, although the bytes do not change, and by 33.08 ± 1.74 points on our renderings of MOTIF at five widths.

We do not claim that malware-as-image accuracy is uniformly an artifact of duplicated data, since Mal-ing loses less than one point under our deduplicated split. Our claim is that inflation must be measured per benchmark, and that the image encoding is not a neutral re-representation of the binary.

References (31)