SparseMax-∂STL

Sound, sparse smoothing for differentiable signal temporal logic in Warp and JAX

Differentiable Signal Temporal Logic (STL) robustness in Warp and in JAX with the SparseMax smoothing, and sparse derivatives of STL-constrained nonlinear programs for model predictive control.

A gradient-based solver that enforces an STL specification uses a smooth approximation of its robustness. SparseMax replaces the minimum and the maximum by lower approximations whose gradients are sparsemax projections: the robustness lies below the exact one with an error bound independent of the number of samples, and its gradient is exactly zero on every sample beyond a data-dependent threshold. On a seven-joint manipulator beside a person, as the horizon grows from 10 to 80 s, the gradient weight of the sound log-sum-exp on the violating samples falls from 0.22 to 0.04, while that of SparseMax stays at 1.

In Warp, a specification is compiled once into an evaluation graph and evaluated by kernels with hand-written adjoints for a batch of trajectories. Paired with MuJoCo Warp, a trajectory optimization runs with no call outside Warp, on a workstation and on a Jetson AGX Orin.