Differentiable Convex Optimization Layers
Not on the map. Why?
Abstract (arXiv)
Recent work has shown how to embed differentiable optimization problems (that is, problems whose solutions can be backpropagated through) as layers within deep learning architectures. This method provides a useful inductive bias for certain problems, but existing software for differentiable optimization layers is rigid and difficult to apply to new settings. In this paper, we propose an approach to differentiating through disciplined convex programs, a subclass of convex optimization problems used by domain-specific languages (DSLs) for convex optimization. We introduce disciplined parametrized programming, a subset of disciplined convex programming, and we show that every disciplined parametrized program can be represented as the composition of an affine map from parameters to problem data, a solver, and an affine map from the solver's solution to a solution of the original problem (a new form we refer to as affine-solver-affine form). We then demonstrate how to efficiently differentiate through each of these components, allowing for end-to-end analytical differentiation through the entire convex program. We implement our methodology in version 1.1 of CVXPY, a popular Python-embedded DSL for convex optimization, and additionally implement differentiable layers for disciplined convex programs in PyTorch and TensorFlow 2.0. Our implementation significantly lowers the barrier to using convex optimization problems in differentiable programs. We present applications in linear machine learning models and in stochastic control, and we show that our layer is competitive (in execution time) compared to specialized differentiable solvers from past work.
Key facts. Cited by 458 papers in the map (data through 7 Oct 2026). First posted on arXiv 28 Oct 2019.
Builds on
No reference list yet.
Built on by
Citing papers per year: 2021: 58; 2022: 68; 2023: 87; 2024: 70; 2025: 70; 2026: 105.
458 papers.
Sort:
By area:
- 2021Efficient and Modular Implicit Differentiationcited by 199
- 2021DC3: A learning method for optimization with hard constraintscited by 181
- 2021Sinkformers: Transformers with Doubly Stochastic Attentioncited by 136
- 2023Decision-Focused Learning: Foundations, State of the Art, Benchmark and Future Opportunitiescited by 129
- 2021Implicit MLE: Backpropagating Through Discrete Exponential Family Distributionscited by 97
- 2022Tutorial on amortized optimizationcited by 83
- 2023A Survey of Contextual Optimization Methods for Decision Making under Uncertaintycited by 81
- 2021Differentiable Learning Under Triagecited by 74
- 2021Neural Monocular 3D Human Motion Capture with Physical Awarenesscited by 70
- 2022Theseus: A Library for Differentiable Nonlinear Optimizationcited by 64
- 2021Strategic Classification Made Practicalcited by 58
- 2022Self-Destructing Models: Increasing the Costs of Harmful Dual Uses of Foundation Modelscited by 56
38 more
- 2022Model-Based Deep Learning: On the Intersection of Deep Learning and Optimizationcited by 50
- 2021CombOptNet: Fit the Right NP-Hard Problem by Learning Integer Programming Constraintscited by 49
- 2022Object Representations as Fixed Points: Training Iterative Refinement Algorithms with Implicit Differentiationcited by 46
- 2025Physics-Constrained Flow Matching: Sampling Generative Models with Hard Constraintscited by 46
- 2021Safe Reinforcement Learning Using Robust Control Barrier Functionscited by 44
- 2021Nonsmooth Implicit Differentiation for Machine Learning and Optimizationcited by 43
- 2021Adversarial Robustness with Semi-Infinite Constrained Learningcited by 39
- 2022D&D: Learning Human Dynamics from Dynamic Cameracited by 39
- 2023End-to-End Feasible Optimization Proxies for Large-Scale Economic Dispatchcited by 35
- 2022Learning differentiable solvers for systems with hard constraintscited by 34
- 2021Extending Lagrangian and Hamiltonian Neural Networks with Differentiable Contact Modelscited by 33
- 2022PyEPO: A PyTorch-based End-to-End Predict-then-Optimize Library for Linear and Integer Programmingcited by 32
- 2021Enforcing Policy Feasibility Constraints through Differentiable Projection for Energy Optimizationcited by 31
- 2023RAYEN: Imposition of Hard Convex Constraints on Neural Networkscited by 30
- 2024Physics-Informed Neural Networks with Hard Linear Equality Constraintscited by 30
- 2022Backpropagation through Combinatorial Algorithms: Identity with Projection Workscited by 29
- 2024HardNet: Hard-Constrained Neural Networks with Universal Approximation Guaranteescited by 29
- 2022Learning with Combinatorial Optimization Layers: a Probabilistic Approachcited by 28
- 2023One-step differentiation of iterative algorithmscited by 28
- 2023Physics-Informed Machine Learning for Modeling and Control of Dynamical Systemscited by 28
- 2022Learning Model Predictive Controllers with Real-Time Attention for Real-World Navigationcited by 27
- 2022Beyond backpropagation: bilevel optimization through implicit differentiation and equilibrium propagationcited by 26
- 2021Integrated Conditional Estimation-Optimizationcited by 25
- 2022Automatic differentiation of nonsmooth iterative algorithmscited by 25
- 2021Differentiable Trust Region Layers for Deep Reinforcement Learningcited by 24
- 2021Implicit differentiation for fast hyperparameter selection in non-smooth convex learningcited by 22
- 2022Alternating Differentiation for Optimization Layerscited by 22
- 2021To The Point: Correspondence-driven monocular 3D category reconstructioncited by 21
- 2022SurCo: Learning Linear Surrogates For Combinatorial Nonlinear Optimization Problemscited by 21
- 2021Robust Implicit Networks via Non-Euclidean Contractionscited by 19
- 2021Efficient differentiable quadratic programming layers: an ADMM approachcited by 19
- 2022End-to-End Stochastic Optimization with Energy-Based Modelcited by 19
- 2025FSNet: Feasibility-Seeking Neural Network for Constrained Optimization with Guaranteescited by 19
- 2021Escaping from Zero Gradient: Revisiting Action-Constrained Reinforcement Learning via Frank-Wolfe Policy Optimizationcited by 18
- 2023Leaving the Nest: Going Beyond Local Loss Functions for Predict-Then-Optimizecited by 18
- 2024TOP-ERL: Transformer-based Off-Policy Episodic Reinforcement Learningcited by 18
- 2025Gen-DFL: Decision-Focused Generative Learning for Robust Decision Makingcited by 18
- 2021Multiset-Equivariant Set Prediction with Approximate Implicit Differentiationcited by 17
50 most cited of 458 All 458 (JSON)
- 2026Verify Claims, Not Scores: Evidence-Based Verification of Modular Agents1 Oct 2026
- 2026Learning to Price Electricity for Optimal Demand Response30 Sep 2026
- 2026Markovian Dynamics Enforcer: Feasibility Preserving Correction on Learned Dynamics Manifolds30 Sep 2026
- 2026Learned Preconditioning for a Primal-Dual Interior-Point Method28 Sep 2026
- 2026dOPT: Differentiating Conic Optimization via Geometric Reduction27 Sep 2026
- 2026lapanda: A Matrix-Free Differentiable Solver for Nonconvex Constrained Optimization Layers27 Sep 2026
- 2026SLP-ProbHard: Probabilistic Hard-Constrained Learning via Structural Latent Parameterization27 Sep 2026
- 2026PolyStepOR: Learning to Decide Without Optimal Decisions26 Sep 2026
- 2026AT-SKM-Net: An Accelerated Trainable Sampling Kaczmarz-Motzkin Framework for Linear Hard-Constraint Feasibility on Dynamic Graphs24 Sep 2026
- 2026Stability-Aware Imitation Learning from Model Predictive Control for Autonomous Vehicle Lateral Control: Exact Q-Loss and a Novel Training Procedure20 Sep 2026
- 2026Proximal Residual Value Functions for Consistent Planning and Real-Time Execution19 Sep 2026
- 2026Generation of Custom Solvers in Rust for Convex Optimization12 Sep 2026
38 more
- 2026Benchmarking Optimizers to Solve Inverse Problems with Differentiable Physics Simulators12 Sep 2026
- 2026GPU-Enabled Large-Scale Optimization Using Randomized Linear Algebra8 Sep 2026
- 2026A Constraint-Aware Generative Framework for Synthetic Origin-Destination Demand in Logistics Networks3 Sep 2026
- 2026Differentiable Electricity-Market Clearing for Gradient-Based Planning2 Sep 2026
- 2026Accelerating Reinforcement Learning via MPC Solver-Gradient Guidance for Weights-varying MPC1 Sep 2026
- 2026Disciplined Bilevel Programming1 Sep 2026
- 2026CG4AI: A Column Generation Framework for Training AI Models Under Constraints26 Aug 2026
- 2026Decision-Driven Regularization: A Blended Model for Learning and Optimization15 Aug 2026
- 2026Constrained Graph Diffusion for Mixed Integer Optimization13 Aug 2026
- 2026Decision-Focused Learning in Network Interdiction Games10 Aug 2026
- 2026Hard Constraints, Smooth Gradients: Learning Feasible Inventory Policies via Differentiable Projection3 Aug 2026
- 2026Differentiable Policy Transport over Multi-Layer Network Feasibility Geometry2 Aug 2026
- 2026End-to-End Fairness Optimization with Fair Decision-Focused Learning31 Jul 2026
- 2026Amortising Trajectory Optimisation for Residual MPC via Implicit Contact Differentiation27 Jul 2026
- 2026Smooth Learning with Hard Constraints via Legendre-Regularized Policies27 Jul 2026
- 2026Memory-Computation Tradeoffs in Semi Amortized Parametric Optimization22 Jul 2026
- 2026End-to-End Learning of Safe Optimal Feedback Control in High Dimensions with Control Barrier Function Layers22 Jul 2026
- 2026Explaining Process Control Optimisation Recommendations via GradientSHAP and Implicit Differentiation16 Jul 2026
- 2026What a Deletion Certificate Covers, and Where It Expires: Auditable Removal from a Support-Vector Memory13 Jul 2026
- 2026Connected by Construction: Learning Tractable Near-Tour Marginals for Traveling Salesman Problems13 Jul 2026
- 2026Neural Certificate Pricing for Combinatorial Optimization Problems1 Jul 2026
- 2026Decision-focused Sparse Tangent Portfolio Optimization1 Jul 2026
- 2026ShardNet: Training Neural Controllers with Hard, Non-Convex Constraints29 Jun 2026
- 2026The Decision Geometry of Covariance Estimation for the Global Minimum-Variance Portfolio under Heavy Tails25 Jun 2026
- 2026Generating Input Distributions for Explaining Portfolio Optimization Pipelines24 Jun 2026
- 2026Constrained Variable Projection for Structured Problems22 Jun 2026
- 2026Decision-Focused Learning: When and Why Traditional Prediction Models Fail19 Jun 2026
- 2026Embedding Linear Equality Constraints in Probabilistic Neural Networks for Dynamic Modelling19 Jun 2026
- 2026A Solver-Free Training Method for Predict-then-Optimize17 Jun 2026
- 2026Decision-Weighted Flow Matching for Contextual Stochastic Optimization15 Jun 2026
- 2026Elastic ODYN: Differentiable Optimization for Infeasible Control and Learning in Robotics15 Jun 2026
- 2026Scalable Deep Unfolding of Conic Optimizers11 Jun 2026
- 2026Bellman-Taylor Score Decoding for Markov Decision Processes with State-Dependent Feasible Action Sets9 Jun 2026
- 2026PL-KKT-hPINN: Enforcing Nonlinear Equality Constraints on Neural Networks via Piecewise-Linear Projection9 Jun 2026
- 2026Who Earns the Safety? Intervention-Aware Quantum Predictive Control with Safety Attribution8 Jun 2026
- 2026DIFFRACT: Neuralized Utility Maximization for Wireless Networks by Differentiable Programming5 Jun 2026
- 2026Deep Single-Index Fr'echet Regression5 Jun 2026
- 2026Multi-ResNets for Subspace Preconditioning in Constrained Optimization4 Jun 2026
50 newest of 458 All 458 (JSON)
- 2024Imperative Learning: A Self-supervised Neuro-Symbolic Learning Framework for Robot Autonomycited by 16
- 2022Differentiable Constrained Imitation Learning for Robot Motion Planning and Controlcited by 7
- 2024DiffTORI: Differentiable Trajectory Optimization for Deep Reinforcement and Imitation Learningcited by 5
- 2024Offline Hierarchical Reinforcement Learning via Inverse Optimizationcited by 4
- 2025ZipMPC: Compressed Context-Dependent MPC Cost via Imitation Learningcited by 2
- 2025Safe Deployment of Offline Reinforcement Learning via Input Convex Action Correctioncited by 2
- 2021Differentiable Robust LQR Layerscited by 0
- 2025Safe Deployment of Offline Reinforcement Learning via Input Convex Action Correction30 Jul 2025
- 2025ZipMPC: Compressed Context-Dependent MPC Cost via Imitation Learning17 Jul 2025
- 2024Offline Hierarchical Reinforcement Learning via Inverse Optimization10 Oct 2024
- 2024Imperative Learning: A Self-supervised Neuro-Symbolic Learning Framework for Robot Autonomy23 Jun 2024
- 2024DiffTORI: Differentiable Trajectory Optimization for Deep Reinforcement and Imitation Learning8 Feb 2024
- 2022Differentiable Constrained Imitation Learning for Robot Motion Planning and Control21 Oct 2022
- 2021Differentiable Robust LQR Layers10 Jun 2021
- 2025Physics-Constrained Flow Matching: Sampling Generative Models with Hard Constraintscited by 46
- 2025DDAT: Diffusion Policies Enforcing Dynamically Admissible Robot Trajectoriescited by 14
- 2026Constraint-Aware Flow Matching: Decision Aligned End-to-End Training for Constrained Samplingcited by 3
- 2026Decision-Weighted Flow Matching for Contextual Stochastic Optimizationcited by 1
- 2026Diff2SP: Diffusion Models for Correlated Scenario Generation in Stochastic Programmingcited by 0
- 2026Decision-Weighted Flow Matching for Contextual Stochastic Optimization15 Jun 2026
- 2026Diff2SP: Diffusion Models for Correlated Scenario Generation in Stochastic Programming4 Jun 2026
- 2026Constraint-Aware Flow Matching: Decision Aligned End-to-End Training for Constrained Sampling12 May 2026
- 2025Physics-Constrained Flow Matching: Sampling Generative Models with Hard Constraints4 Jun 2025
- 2025DDAT: Diffusion Policies Enforcing Dynamically Admissible Robot Trajectories20 Feb 2025
- 2023Learning Stability Attention in Vision-based End-to-end Driving Policiescited by 5
- 2023Generating Transferable Adversarial Simulation Scenarios for Self-Driving via Neural Renderingcited by 3
- 2025Drive in Corridors: Enhancing the Safety of End-to-end Autonomous Driving via Corridor Learning and Planningcited by 0
- 2026Stability-Aware Imitation Learning from Model Predictive Control for Autonomous Vehicle Lateral Control: Exact Q-Loss and a Novel Training Procedurecited by 0
- 2026Stability-Aware Imitation Learning from Model Predictive Control for Autonomous Vehicle Lateral Control: Exact Q-Loss and a Novel Training Procedure20 Sep 2026
- 2025Drive in Corridors: Enhancing the Safety of End-to-end Autonomous Driving via Corridor Learning and Planning10 Apr 2025
- 2023Generating Transferable Adversarial Simulation Scenarios for Self-Driving via Neural Rendering27 Sep 2023
- 2023Learning Stability Attention in Vision-based End-to-end Driving Policies5 Apr 2023
- 2024Adversarial Machine Unlearningcited by 16
- 2025Learning Safety Constraints for Large Language Modelscited by 13
- 2025Learning Safety Constraints for Large Language Models30 May 2025
- 2024Adversarial Machine Unlearning11 Jun 2024
- 2021Efficient and Modular Implicit Differentiationcited by 199
- 2021DC3: A learning method for optimization with hard constraintscited by 181
- 2021Sinkformers: Transformers with Doubly Stochastic Attentioncited by 136
- 2023Decision-Focused Learning: Foundations, State of the Art, Benchmark and Future Opportunitiescited by 129
- 2021Implicit MLE: Backpropagating Through Discrete Exponential Family Distributionscited by 97
- 2022Tutorial on amortized optimizationcited by 83
- 2023A Survey of Contextual Optimization Methods for Decision Making under Uncertaintycited by 81
- 2021Differentiable Learning Under Triagecited by 74
- 2021Neural Monocular 3D Human Motion Capture with Physical Awarenesscited by 70
- 2022Theseus: A Library for Differentiable Nonlinear Optimizationcited by 64
- 2021Strategic Classification Made Practicalcited by 58
- 2022Self-Destructing Models: Increasing the Costs of Harmful Dual Uses of Foundation Modelscited by 56
12 most cited of 435 All 435 (JSON)
- 2026Verify Claims, Not Scores: Evidence-Based Verification of Modular Agents1 Oct 2026
- 2026Learning to Price Electricity for Optimal Demand Response30 Sep 2026
- 2026Markovian Dynamics Enforcer: Feasibility Preserving Correction on Learned Dynamics Manifolds30 Sep 2026
- 2026Learned Preconditioning for a Primal-Dual Interior-Point Method28 Sep 2026
- 2026dOPT: Differentiating Conic Optimization via Geometric Reduction27 Sep 2026
- 2026lapanda: A Matrix-Free Differentiable Solver for Nonconvex Constrained Optimization Layers27 Sep 2026
- 2026SLP-ProbHard: Probabilistic Hard-Constrained Learning via Structural Latent Parameterization27 Sep 2026
- 2026PolyStepOR: Learning to Decide Without Optimal Decisions26 Sep 2026
- 2026AT-SKM-Net: An Accelerated Trainable Sampling Kaczmarz-Motzkin Framework for Linear Hard-Constraint Feasibility on Dynamic Graphs24 Sep 2026
- 2026Proximal Residual Value Functions for Consistent Planning and Real-Time Execution19 Sep 2026
- 2026Generation of Custom Solvers in Rust for Convex Optimization12 Sep 2026
- 2026Benchmarking Optimizers to Solve Inverse Problems with Differentiable Physics Simulators12 Sep 2026
12 newest of 435 All 435 (JSON)