TL;DR
Deep regression often underperforms compared to classification-based approaches because standard regression losses (like Mean Squared Error) lead to "collapsed" feature spaces with low entropy. This paper introduces an Ordinal Entropy regularizer that encourages more diverse, high-entropy feature representations while preserving the natural ordering of labels, significantly boosting performance across tasks like depth estimation, age prediction, and crowd counting.
What Problem Does This Paper Address?
In computer vision, researchers have long noticed a "curious phenomenon": even when a task is inherently continuous (like estimating the depth of a pixel or the age of a person), discretizing the labels and treating the problem as a classification task often yields better results than direct regression.
While previous work suggested task-specific reasons for this—such as it being "easier" to predict a range than a precise value—this paper digs deeper into representation learning. The authors argue that the standard Mean Squared Error (MSE) loss used in regression fails to encourage "diversity" in the learned features.
Specifically, while classification losses (like Cross-Entropy) naturally push different classes apart in the feature space, MSE only focuses on pulling features toward their targets. This leads to a "collapsed" feature space with low marginal entropy, where the model struggles to distinguish fine-grained differences between samples.
Methods
The authors analyze the problem through the lens of Mutual Information. They show that for a model to learn robustly, it should maximize the mutual information between the learned representation ($Z$) and the target ($Y$). This involves two primary goals:
- Tightness: Features of the same target should be close together (low conditional entropy).
- Diversity: Features of different targets should be spread as far apart as possible (high marginal entropy).
They mathematically demonstrate that while MSE handles "tightness" well, it completely ignores "diversity." To fix this, they propose the Ordinal Entropy ($L_{oe}$) regularizer, which consists of two terms:
- Diversity Term ($L_d$): This term pushes feature centers away from each other to increase entropy. Crucially, it weights the "push" based on the distance between labels in the target space. This ensures that the model doesn't just spread features randomly but maintains their ordinal relationship (e.g., the feature for "age 20" stays closer to "age 21" than to "age 80").
- Tightness Term ($L_t$): This ensures individual samples stay close to their respective feature centers.
The final training objective is a combination of the standard regression loss and these two new regularizers.
Key Insights and Ideas
- Feature Collapse in Regression: Standard regression models tend to cluster all features into a very small portion of the available feature space. This lack of "spread" makes the model less robust and less capable of distinguishing fine differences.
- Entropy as a Proxy for Performance: By visualizing feature spaces, the authors show that classification models produce "spread out" features, while regression models produce "clumped" ones. Their regularizer successfully emulates the high-entropy spread of classification within a regression framework.
- Preserving Ordinality: Unlike standard contrastive learning (which treats all "different" samples equally), regression requires maintaining a sense of scale. The "Ordinal" part of their entropy regularizer is the "secret sauce" that allows features to spread out without breaking the underlying continuous logic of the task.
Datasets and Key Results
The authors evaluated their method across a diverse set of synthetic and real-world benchmarks, including synthetic operators, NYU-Depth-v2 (depth estimation), ShanghaiTech (crowd counting), and AgeDB-DIR (age estimation).
The proposed regularizer acted as a "plug-and-play" boost for several state-of-the-art (SOTA) models:
- Depth Estimation: Adding Ordinal Entropy to the SOTA NeW-CRFs model improved the $\delta_1$ accuracy metric and reduced the Relative Error (REL) by 6.3%.
- Crowd Counting: On the ShanghaiTech SHA dataset, the Mean Absolute Error (MAE) dropped from 68.2 to 65.6.
- Age Estimation: The method showed significant gains, particularly in "Few-shot" scenarios (where data for certain ages is scarce), improving MAE from 13.67 to 12.38.
- Efficiency: The authors show that while the regularizer adds some computation during training, the overhead is negligible for real-world backbones like ResNet-50, and it adds zero cost to inference time.
Limitations and Future Work
- Sample Size Sensitivity: The diversity term involves calculating pairwise distances between samples in a batch. While the authors show it works even with small samples, the complexity is quadratic ($O(M^2)$), which might require careful subsampling for extremely large batches or high-dimensional features.
- Hyperparameter Tuning: The method introduces two new trade-off parameters ($\lambda_d$ and $\lambda_t$). While the authors found stable values across tasks, some tuning is likely necessary when applying this to entirely new domains.
- Beyond MSE: The theoretical derivation focuses on $L_2$ (MSE) loss. Future work could explore how these entropy principles apply to other regression losses like $L_1$ or Log-Cosh.
Summary updated