Abstract: This research addresses the fundamental conflict between data compression and neural network performance in computer vision. While entropy coding is essential for efficient data storage and transmission, it often destroys the spatial and semantic patterns that Convolutional Neural Networks (CNNs) rely on for learning. We present a "chaos metric" based on approximate entropy that predicts accuracy loss when training in the compressed domain, providing a computationally efficient alternative to exhaustive model retraining.
Introduction
In contemporary computer vision, the vast majority of visual data is processed by machines rather than humans. Traditionally, data is compressed for storage and then fully decoded before being fed into a CNN. Eliminating the decoding step—a paradigm known as "learning in the compressed domain"—could yield massive savings in computation and energy. However, the final stage of standard compression, entropy coding (such as Huffman or Arithmetic coding), introduces significant "chaos" into the data representation.
Entropy coding typically disrupts two fundamental properties that CNNs exploit:
- Spatial Proximity: Pixels that are neighbors in the physical world should remain "near" each other in the data representation.
- Semantic Proximity: Similar visual features, such as color or intensity, should be represented by similar numerical values.
By shuffling data into variable-length symbols based on frequency, entropy coding destroys these proximities. This paper seeks to quantify this disruption to understand and predict its impact on model accuracy.
System Architecture
The distinction between traditional processing and compressed-domain learning is central to this study. The following diagrams illustrate the two different pipelines evaluated by the researchers.
In the traditional pipeline (a), the source data $Y$ is encoded into a compressed form $X'$, then decoded by function $g$ back to $X$ before the classifier $\phi$ generates an estimate $\hat{Y}$. In the compressed-domain pipeline (b), the classifier $\phi'$ must learn to interpret the encoded bitstream $X'$ directly to produce an estimate $\tilde{Y}$.
Methodology: The Chaos Metric
The authors propose a new metric, $D_f(X)$, to quantify the level of chaos introduced by a coding function $f$ on a dataset $X$. The core of this metric is Approximate Entropy (ApEn), a technique from information theory used to measure the unpredictability or "regularity" of a sequence.
Since the target CNN (UVGG11) processes data bit by bit, the researchers calculate the ApEn for each bit-plane of the image, from the Most Significant Bit (MSB) to the Least Significant Bit (LSB). The chaos metric is defined as the ratio of the sum of ApEn of the coded bit-planes to the sum of ApEn of the original bit-planes. A higher ratio indicates greater chaos and, consequently, a predicted drop in classification accuracy.
Experimental Results
The approach was validated using grayscale versions of the MNIST and CIFAR-10 (YCIFAR-10) datasets. The study compared two major entropy coding families: Huffman Coding and Arithmetic Coding, across various symbol sizes.
- Accuracy Degradation: On the MNIST dataset, accuracy fell from 98.9% (uncompressed) to 83.2% with Huffman coding and 63.1% with Arithmetic coding.
- Predictive Power: The chaos metric $D_f(X)$ successfully ranked the performance of different configurations. It revealed that Arithmetic coding—while generally more efficient for compression—is significantly more destructive to learnable patterns than Huffman coding.
- Monotonicity: A key finding is the monotonic relationship between the chaos metric and accuracy. As the measured chaos increases, accuracy decreases in a predictable, consistent way across different coders and symbol sizes, making the metric a reliable proxy for performance.
Conclusion and Future Work
The proposed chaos metric offers a computationally efficient way to "preview" the impact of a compression algorithm on AI performance. By relying solely on the encoded data, it bypasses the need for time-consuming network retraining.
While promising, the study notes several areas for future exploration. The current experiments were limited to grayscale data and a specific unidimensional CNN architecture (UVGG11). Future work will focus on extending this metric to multi-channel color data and evaluating its predictive accuracy for more complex architectures, such as standard 2D CNNs or Transformers, and advanced video codecs like HEVC.
Summary updated