gwsnr: A python package for efficient signal-to-noise calculation of gravitational-waves

Hemantakumar Phurailatpam, Otto Akseli Hannuksela

arXiv:2412.09888·astro-ph.IM·Published 2024-12-13·Updated 2025-10-29

Gravitational wave astrophysics requires accurate evaluation of the Signal-to-Noise Ratio (SNR) and the Probability of Detection (Pdet) for applications such as population simulations and hierarchical Bayesian inference with selection effects. Traditional approaches for computing SNR are often computationally demanding and inefficient for large-scale analyses. The gwsnr Python package addresses this challenge by providing efficient and flexible tools for calculating the optimal SNR. It features a user-friendly interface and employs techniques such as a partial-scaling interpolation method for non-precessing binaries, a multiprocessing inner-product routine for frequency-domain waveforms that include spin precession and subdominant modes, among others. High computational performance is achieved through NumPy vectorization and Just-in-Time compilation with Numba, with optional GPU acceleration using JAX and MLX. By combining efficiency, scalability, and ease of use, gwsnr enables large-scale simulations of detectable compact binary mergers and facilitates robust modeling of selection effects through Pdet.

TopicsAstrophysics & Cosmology

Tagsastrophysics bayesian-inference

arXiv categoriesastro-ph.IM, astro-ph.HE

arXiv abstract pagePDF