  Deep learning methods have been employed in gravitational-wave astronomy to
accelerate the construction of surrogate waveforms for the inspiral of
spin-aligned black hole binaries, among other applications. We face the
challenge of modeling the residual error of an artificial neural network that
models the coefficients of the surrogate waveform expansion (especially those
of the phase of the waveform) which we demonstrate has sufficient structure to
be learnable by a second network. Adding this second network, we were able to
reduce the maximum mismatch for waveforms in a validation set by 13.4 times. We
also explored several other ideas for improving the accuracy of the surrogate
model, such as the exploitation of similarities between waveforms, the
augmentation of the training set, the dissection of the input space, using
dedicated networks per output coefficient and output augmentation. In several
cases, small improvements can be observed, but the most significant improvement
still comes from the addition of a second network that models the residual
error. Since the residual error for more general surrogate waveform models
(when e.g., eccentricity is included) may also have a specific structure, one
can expect our method to be applicable to cases where the gain in accuracy
could lead to significant gains in computational time.
