Abstract
As Deep Neural Networks (DNNs) are increasingly integrated into safety-critical domains like autonomous driving and healthcare, formal verification tools—known as DNN certifiers—have become essential for providing mathematical safety guarantees. However, the correctness of these certifiers themselves typically relies on manual, error-prone proofs. This paper introduces ProveSound, an automated framework designed to verify the soundness of DNN certifiers. By utilizing a domain-specific language (ConstraintFlow) and a novel "Symbolic DNN" representation, ProveSound transforms complex soundness proofs into tractable SMT queries. We demonstrate ProveSound's efficacy by verifying seven state-of-the-art certifiers, detecting programmatically injected bugs, and validating a new, more precise abstract domain called PolyZ.
Introduction
The deployment of DNNs in high-stakes environments necessitates rigorous safety certificates. These certificates are often generated using Abstract Interpretation, a technique where a certifier calculates an "over-approximation" of a network's possible outputs for a given range of inputs. If this over-approximation remains within safe bounds, the network is deemed secure against adversarial perturbations or environmental noise.
However, a fundamental challenge remains: "Who guards the guardians?" If the mathematical logic within the certifier is flawed (unsound), the safety certificates it produces are invalid. Historically, ensuring soundness required expert-level manual proofs that are difficult to scale and maintain. ProveSound addresses this by automating the verification process, allowing researchers to guarantee the correctness of existing tools and rapidly prototype new ones.
The Challenge of Automated Soundness
Automating soundness proofs for DNN certifiers is computationally difficult because a certifier must be proven sound for any possible DNN architecture. This leads to "universal quantification" problems—mathematical statements that must hold true across an infinite variety of network topologies and weights. Such problems typically overwhelm standard automated reasoning tools. To overcome this, ProveSound decouples the certifier's logic from the specific network structure, focusing on the local operations that define the certifier's behavior.
The ProveSound Framework
ProveSound employs a multi-layered approach to make automated verification tractable:
- ConstraintFlow DSL: The framework introduces ConstraintFlow, a Domain Specific Language that allows developers to specify the mathematical logic of a certifier (e.g., how it handles ReLU or Affine layers). This DSL abstracts away implementation-level complexities like memory management, focusing purely on the mathematical transformations.
- Symbolic DNNs: The core innovation of ProveSound is the use of Symbolic DNNs. Instead of testing a certifier against specific concrete networks, the system uses an abstract representation that captures all possible subgraphs a certifier might encounter.
- Dynamic Expansion: To handle operations that involve multiple neurons (like
maportraverse), ProveSound statically analyzes the certifier's code and expands the symbolic DNN to include the exact number of symbolic neurons and metadata fields required for the proof. - SMT-Based Verification: The framework translates the certifier’s logic and the symbolic DNN into logic queries for the Z3 SMT solver. The solver checks the "soundness property": the requirement that the abstract output calculated by the certifier always contains the actual concrete output of the network.
Experimental Evaluation
To evaluate ProveSound, the authors benchmarked the tool against several targets:
- State-of-the-Art Certifiers: Specifications for IBP, DeepPoly, CROWN, DeepZ, RefineZono, Vegas, and Hybrid Zonotope.
- Bug Detection: A dataset of "Unsound Transformers" created by injecting random errors (e.g., swapping operators or bounds) into existing certifiers to test ProveSound’s diagnostic capabilities.
- Novel Designs: Two new certifier variants (BALANCE Cert and REUSE Cert) and a new abstract domain (PolyZ).
Key Insights and Results
ProveSound successfully verified the soundness of seven major existing DNN certifiers and correctly identified all programmatically injected bugs. The framework proved to be highly efficient, with most primitive operations (such as ReLU or Max) verified or disproved in under one second.
Furthermore, the tool demonstrated significant scalability, verifying Affine transformers for layers with up to 8,192 neurons—representing over 64 million parameters—in approximately 32,000 seconds. A notable discovery was the verification of PolyZ, a new abstract domain that offers higher precision than widely used domains like DeepPoly and DeepZ.
The "aha moment" of the research is the realization that global soundness can be guaranteed through local proofs. By proving a certifier is sound on a small, symbolic subgraph representing arbitrary local structures, ProveSound provides a mathematical guarantee for networks of any size or topology.
Limitations and Future Work
While ProveSound is a significant step forward, it faces challenges with non-linear activations like Sigmoid and Tanh, which are currently undecidable in the SMT theories used. Future work may involve using $\delta$-complete decision procedures to address these functions. Additionally, while the tool currently verifies designs, a promising future direction is automatic synthesis, where the framework could generate the most precise sound transformer for a new DNN operation automatically.
Conclusion
ProveSound provides a robust, automated foundation for the development of trustworthy DNN safety tools. By bridging the gap between complex mathematical proofs and automated logic solvers, it ensures that the "guardians" of neural network safety are themselves mathematically sound.
Summary updated