mlsanityData to 14 Oct 2026

NaN-Propagation: A Novel Method for Sparsity Detection in Black-Box Computational Functions

arXiv 2507.23186 ↗First posted 31 Jul 2025cs.LG cs.PLcited by 0

Not on the map. Why?

Abstract (arXiv)

When numerically evaluating a function's gradient, sparsity detection can enable substantial computational speedups through Jacobian coloring and compression. However, sparsity detection techniques for black-box functions are limited, and existing finite-difference-based methods suffer from false negatives due to coincidental zero gradients. These false negatives can silently corrupt gradient calculations, leading to difficult-to-diagnose errors. We introduce NaN-propagation, which exploits the universal contamination property of IEEE 754 Not-a-Number values to trace input-output dependencies through floating-point numerical computations. By systematically contaminating inputs with NaN and observing which outputs become NaN, the method reconstructs conservative sparsity patterns that eliminate a major source of false negatives. We demonstrate this approach on an aerospace wing weight model, achieving a 1.52x speedup while uncovering dozens of dependencies missed by conventional methods -- a significant practical improvement since gradient computation is often the bottleneck in optimization workflows. The technique leverages IEEE 754 compliance to work across programming languages and math libraries without requiring modifications to existing black-box codes. Furthermore, advanced strategies such as NaN payload encoding via direct bit manipulation enable faster-than-linear time complexity, yielding speed improvements over existing black-box sparsity detection methods. Practical algorithms are also proposed to mitigate challenges from branching code execution common in engineering applications.

Key facts. No citing papers in the map yet (data through 14 Oct 2026). Builds on 2 of its 14 references that are in the map. First posted on arXiv 31 Jul 2025.

Builds on

2 of 14 references.

References · 2

  1. 2025Sparser, Better, Faster, Stronger: Sparsity Detection for Efficient Automatic Differentiationcited by 4
  2. 2017Transcription Methods for Trajectory Optimization: a beginners tutorialcited by 1

Built on by

Not cited yet.