Convexity in ReLU Neural Networks: beyond ICNNs?
Anne Gagneux, Mathurin Massias, Emmanuel Soubies, Rémi Gribonval
TL;DR
The paper tackles when ReLU networks implement convex functions and introduces a path-lifting framework to derive necessary and sufficient convexity conditions. It proves that 1-hidden-layer networks coincide with ICNNs, but 2-hidden-layer networks can realize convex CPWL functions beyond ICNNs and provides explicit counterexamples. A general DAG-ReLU analysis with path-lifting yields both necessary and (under mild non-degeneracy) sufficient convexity criteria, plus a practical numerical algorithm to check convexity on networks with many affine regions. The findings reveal substantial expressive life beyond ICNNs, enabling exact convexity tests and suggesting regularizers to promote convexity during training, with implications for imaging, proximal methods, and optimal transport. These results bridge CPWL convexity theory with modern neural architectures, highlighting both theoretical and practical gains in guaranteeing convex priors in learned models.
Abstract
Convex functions and their gradients play a critical role in mathematical imaging, from proximal optimization to Optimal Transport. The successes of deep learning has led many to use learning-based methods, where fixed functions or operators are replaced by learned neural networks. Regardless of their empirical superiority, establishing rigorous guarantees for these methods often requires to impose structural constraints on neural architectures, in particular convexity. The most popular way to do so is to use so-called Input Convex Neural Networks (ICNNs). In order to explore the expressivity of ICNNs, we provide necessary and sufficient conditions for a ReLU neural network to be convex. Such characterizations are based on product of weights and activations, and write nicely for any architecture in the path-lifting framework. As particular applications, we study our characterizations in depth for 1 and 2-hidden-layer neural networks: we show that every convex function implemented by a 1-hidden-layer ReLU network can be also expressed by an ICNN with the same architecture; however this property no longer holds with more layers. Finally, we provide a numerical procedure that allows an exact check of convexity for ReLU neural networks with a large number of affine regions.
