English

On the derivatives of feed-forward neural networks

Computational Physics 2020-05-15 v1 High Energy Physics - Phenomenology

Abstract

In this paper we present a C++ implementation of the analytic derivative of a feed-forward neural network with respect to its free parameters for an arbitrary architecture, known as back-propagation. We dubbed this code NNAD (Neural Network Analytic Derivatives) and interfaced it with the widely-used ceres-solver minimiser to fit neural networks to pseudodata in two different least-squares problems. The first is a direct fit of Legendre polynomials. The second is a somewhat more involved minimisation problem where the function to be fitted takes part in an integral. Finally, using a consistent framework, we assess the efficiency of our analytic derivative formula as compared to numerical and automatic differentiation as provided by ceres-solver. We thus demonstrate the advantage of using NNAD in problems involving both deep or shallow neural networks.

Keywords

Cite

@article{arxiv.2005.07039,
  title  = {On the derivatives of feed-forward neural networks},
  author = {Rabah Abdul Khalek and Valerio Bertone},
  journal= {arXiv preprint arXiv:2005.07039},
  year   = {2020}
}