arXiv Science⌕ Search

arXiv subjects

Adrian Hill

Publications and source records attributed to Adrian Hill.

11 recordsLinked to original sources

Block-Sparse Gauss-Newton Optimization of Finite Basis Physics-Informed Neural Networks: Sparse Automatic Differentiation Approach

In this work, we develop an efficient Gauss-Newton optimization approach for finite basis physics-informed neural networks (FBPINNs). The key ingredient is the overlapping domain decomposition architecture of FBPINNs, which localizes the influence of each subnetwork and induces block sparsity in both the residual Jacobian and the corresponding Gauss-Newton matrix. We characterize this structure and exploit it through sparse automatic differentiation, using graph coloring to partition structurally orthogonal Jacobian columns or rows. This reduces differentiation costs and memory requirements while preserving all structurally nonzero derivative information. The resulting compressed Jacobian representations allow us to assemble the Gauss-Newton system directly in block-sparse form, enabling the use of sparse direct solvers and preconditioned iterative methods. In this way, the otherwise expensive second-order optimization problem is reduced to scalable sparse linear algebra. We demonstrate the approach on multiscale PDEs, where accurate approximation requires rich neural network parametrizations and large numbers of collocation points. Numerical experiments show that our block-sparse Gauss-Newton method attains high accuracy and substantially accelerates optimization relative to first-order baselines while remaining computationally tractable for large problem sizes.

math.NA↗

asdex: Automatic Sparse Differentiation in JAX

Many tasks in scientific computing and machine learning require the Jacobian or Hessian matrix of a function. Automatic differentiation (AD) computes these derivatives to machine precision, but materializing a dense $m \times n$ Jacobian requires $n$ forward-mode or $m$ reverse-mode AD passes, one per column or row. For a large class of functions, each output depends on only a few inputs, making the derivative matrix sparse. Automatic sparse differentiation (ASD) exploits this structure in four steps: detection of the input-agnostic sparsity pattern, coloring of a graph to group columns or rows that can share an AD pass, compressed differentiation to compute a compressed derivative matrix with one AD pass per color, and finally decompression into the original sparsity pattern. The number of colors, and hence of AD passes, is often independent of the problem dimension: a banded Jacobian with $b$ contiguous bands, for instance, only ever requires $b$ colors, regardless of its size. asdex offers the first standalone ASD toolkit in the popular JAX ecosystem. With $\texttt{asdex.jacobian}$ and $\texttt{asdex.hessian}$, it provides sparse drop-in replacements for $\texttt{jax.jacobian}$ and $\texttt{jax.hessian}$.

cs.MS↗

Truncated automatic sparse differentiation for machine learning interatomic potentials

Machine learning interatomic potentials (MLIPs) learn the mapping from atomic positions to potential energy. The forces, the negative gradient of this energy, drive molecular dynamics and are readily obtained using automatic differentiation. Higher-order derivatives, most notably the Hessian, describe collective motion and allow the direct prediction of experimental observables, but are considered computationally inaccessible for large systems. We suggest a solution: in physical systems, interactions decay with distance, and most MLIPs build on this locality through message passing up to a finite receptive field. This implies both sparsity of higher-order derivatives and their decay with distance. This structure can be exploited using automatic sparse differentiation (ASD). We explain how to compute the sparsity pattern for MLIP derivatives and demonstrate that, for multiple foundation MLIPs, ASD computes full Hessians of large porous materials exactly, but with modest speedups at best. The larger gains come from truncated ASD: discarding small, but nonzero, Hessian entries between distant atoms yields order-of-magnitude speedups with negligible impact on predicted observables.

physics.chem-ph↗

Sparser, Better, Faster, Stronger: Sparsity Detection for Efficient Automatic Differentiation

From implicit differentiation to probabilistic modeling, Jacobian and Hessian matrices have many potential use cases in Machine Learning (ML), but they are viewed as computationally prohibitive. Fortunately, these matrices often exhibit sparsity, which can be leveraged to speed up the process of Automatic Differentiation (AD). This paper presents advances in sparsity detection, previously the performance bottleneck of Automatic Sparse Differentiation (ASD). Our implementation of sparsity detection is based on operator overloading, able to detect both local and global sparsity patterns, and supports flexible index set representations. It is fully automatic and requires no modification of user code, making it compatible with existing ML codebases. Most importantly, it is highly performant, unlocking Jacobians and Hessians at scales where they were considered too expensive to compute. On real-world problems from scientific ML, graph neural networks and optimization, we show significant speed-ups of up to three orders of magnitude. Notably, using our sparsity detection system, ASD outperforms standard AD for one-off computations, without amortization of either sparsity detection or matrix coloring.

cs.LG↗

A Common Interface for Automatic Differentiation

For scientific machine learning tasks with a lot of custom code, picking the right Automatic Differentiation (AD) system matters. Our Julia package DifferentiationInterface$.$jl provides a common frontend to a dozen AD backends, unlocking easy comparison and modular development. In particular, its built-in preparation mechanism leverages the strengths of each backend by amortizing one-time computations. This is key to enabling sophisticated features like sparsity handling without putting additional burdens on the user.

cs.MS↗

Porting the microphysics model CASIM to GPU and KNL Cray machines

CASIM is a microphysics scheme which calculates the interaction between moisture droplets in the atmosphere and forms a critical part of weather and climate modelling codes. However the calculations involved are computationally intensive and so investigating whether CASIM can take advantage of novel hardware architectures and the likely increase in performance this might afford makes sense. In this paper we present work done in porting CASIM to GPUs via the directive driven OpenACC and also modifying CASIM to take advantage of the Knights Landing (KNL) processor using OpenMP. Due to the design, models extracting out specific computational kernels for offload to the GPU proved suboptimal and instead the entire scheme was ported over to the GPU. We consider the suitability and maturity of OpenACC for this approach as well as important optimisations that were identified. Enabling CASIM to take advantage of the KNL was significantly easier, but still required careful experimentation to understand the best design and configuration. The performance of both versions of CASIM, in comparison to the latest generation of CPUs is discussed, before identifying lessons learnt about the suitability of CASIM and other similar models for these architectures. The result of this work are versions of CASIM which show promising performance benefits when utilising both GPUs and KNLs and enable the communities to take advantage of these technologies, in addition to general techniques that can be applied to other similar weather and climate models.

cs.DC↗

In-situ data analytics for highly scalable cloud modelling on Cray machines

MONC is a highly scalable modelling tool for the investigation of atmospheric flows, turbulence and cloud microphysics. Typical simulations produce very large amounts of raw data which must then be analysed for scientific investigation. For performance and scalability reasons this analysis and subsequent writing to disk should be performed in-situ on the data as it is generated however one does not wish to pause the computation whilst analysis is carried out. In this paper we present the analytics approach of MONC, where cores of a node are shared between computation and data analytics. By asynchronously sending their data to an analytics core, the computational cores can run continuously without having to pause for data writing or analysis. We describe our IO server framework and analytics workflow, which is highly asynchronous, along with solutions to challenges that this approach raises and the performance implications of some common configuration choices. The result of this work is a highly scalable analytics approach and we illustrate on up to 32768 computational cores of a Cray XC30 that there is minimal performance impact on the runtime when enabling data analytics in MONC and also investigate the performance and suitability of our approach on the KNL.

cs.DC↗

A highly scalable Met Office NERC Cloud model

Large Eddy Simulation is a critical modelling tool for scientists investigating atmospheric flows, turbulence and cloud microphysics. Within the UK, the principal LES model used by the atmospheric research community is the Met Office Large Eddy Model (LEM). The LEM was originally developed in the late 1980s using computational techniques and assumptions of the time, which means that the it does not scale beyond 512 cores. In this paper we present the Met Office NERC Cloud model, MONC, which is a re-write of the existing LEM. We discuss the software engineering and architectural decisions made in order to develop a flexible, extensible model which the community can easily customise for their own needs. The scalability of MONC is evaluated, along with numerous additional customisations made to further improve performance at large core counts. The result of this work is a model which delivers to the community significant new scientific modelling capability that takes advantage of the current and future generation HPC machines.

cs.SE↗

A directive based hybrid Met Office NERC Cloud model

Large Eddy Simulation is a critical modelling tool for the investigation of atmospheric flows, turbulence and cloud microphysics. The models used by the UK atmospheric research community are homogeneous and the latest model, MONC, is designed to run on substantial HPC systems with very high CPU core counts. In order to future proof these codes it is worth investigating other technologies and architectures which might support the communities running their codes at the exa-scale. In this paper we present a hybrid version of MONC, where the most computationally intensive aspect is offloaded to the GPU while the rest of the functionality runs concurrently on the CPU. Developed using the directive driven OpenACC, we consider the suitability and maturity of this technology to modern Fortran scientific codes as well general software engineering techniques which aid this type of porting work. The performance of our hybrid model at scale is compared against the CPU version before considering other tuning options and making a comparison between the energy usage of the homo- and hetero-geneous versions. The result of this work is a promising hybrid model that shows performance benefits of our approach when the GPU has a significant computational workload which can not only be applied to the MONC model but also other weather and climate simulations in use by the community.

cs.DC↗

Designing a new spatial light modulator for holographic photostimulation

Driven by the demands for speed and field of view in the holographic photostimulation community, we designed, built, and tested a liquid crystal on silicon (LCoS) spatial light modulator (SLM) with a 1536x1536 square pixel array and high-voltage LC drive. We discuss some of the engineering work that made the MacroSLM possible, including the custom FPGA board for handling huge data rates, the large pixel size for minimizing rolloff and crosstalk, and the temperature control to handle heating effects from the high-voltage controls and high-power laser illumination. We also designed an FPGA implementation of the overdrive method for increasing liquid crystal switching speed, allowing us to overcome the significant data bottlenecks that limit frame rates for large arrays. We demonstrate 500 Hz hologram-to-hologram speed at 1064 nm operating wavelength, and discuss the new science that these speeds and array sizes have enabled.

physics.ins-det↗

Symmetric general linear methods

The article considers symmetric general linear methods, a class of numerical time integration methods which, like symmetric Runge--Kutta methods, are applicable to general time--reversible differential equations, not just those derived from separable second--order problems. A definition of time--reversal symmetry is formulated for general linear methods, and criteria are found for the methods to be free of linear parasitism. It is shown that symmetric parasitism--free methods cannot be explicit, but a method of order $4$ is constructed with only one implicit stage. Several characterizations of symmetry are given, and connections are made with $G$--symplecticity. Symmetric methods are shown to be of even order, a suitable symmetric starting method is constructed and shown to be essentially unique. The underlying one--step method is shown to be time--symmetric. Several symmetric methods of order $4$ are constructed and implemented on test problems. The methods are efficient when compared with Runge--Kutta methods of the same order, and invariants of the motion are well--approximated over long time intervals.

math.NA↗