Skip to text

5 Compositionality

Optimization models often appear as components in other optimization models. This is the case in decomposition techniques, bilevel optimization, and stochastic optimization for instance. One interesting question is whether optimization proxies can be as compositional as traditional optimization models. A neural network with ReLU activation functions can be encoded as a MIP, but this is not necessarily desirable given the resulting nonconvexities and computational challenges. An intriguing possibility is the use of convex neural networks, or more precisely, Input-Convex Neural Networks (ICNNs). A neural network with ReLU activation functions computes a convex function if all its weights are constrained to be nonnegative. An input-convex neural network generalizes the idea: it adds a first layer whose weights are unconstrained, and skip connections to all other “convex” layers. More precisely, the kth layer ( k>0) of an input-convex neural network is of the form

(9.4)xk=hk(xk−1)=ReLU(Wkxk−1+Hkx0+dk),

where xk and xk−1 denote the outputs of layer k and k−1, x0 denotes the input of the ICNN, dk is the bias vector, and Wk, Hk are weight matrices. Skip-connections feed the ICNN input x0 to each layer. The coefficients of Wk are nonnegative, whereas Hk may take positive or negative values without affecting convexity [1]. Once trained, the input-convex neural network defines a convex function and its gradients with respect to its inputs, which meets the requirements of a number of applications. It has been shown that input-convex neural networks can approximate the objective value of AC-OPF, its second-order cone relaxation, and its DC approximation with high accuracy, opening many promising avenues for practical applications [23]. For instance, Figure 9.7 compares the accuracy of an ICNN and a regular ReLU-based neural networks for estimating the objective value of the SOCP relaxation of the optimal power flow on the RTE network.

Figure 9.7 The performance of ICNNs on the SOCP relaxation of optimal power flow (from [23]).

When successful, a trained ICCN provides a high-fidelity approximation of the value function of an optimization problem and its gradients with respect to the inputs. This is exactly the functionalities needed by Benders decomposition (and its generalizations) when applied to deterministic and stochastic optimization problems. The ICCN can then replace a complex optimization subproblem to speed up these applications when only the optimal sub-objective value and its gradients are needed. ICNNs should also be useful for bilevel optimization problems, although case studies are necessary to demonstrate their benefits in these settings.