text: Machine learning modelling of the gravitational waves generated by black-hole binaries
  Project description
  mlgw
  Author Stefano Schmidt
  Licence CC BY 4.0
  Version 1.1.0
  MACHINE LEARNING MODEL FOR THE GRAVITATIONAL WAVES GENERATED BY BLACK-HOLE BINARIES
  mlgw (Machine Learning Gravitational Waves) is a useful tool to quickly generate a GW waveform for a BBH coalescence. It is part of a Master thesis work at University of Pisa (Italy) under supervision of prof. Walter Del Pozzo. from mpl_toolkits.axes_grid.inset_locator import (inset_axes, InsetPosition,mark_inset) #generating the wave generator = generator.GW_generator() #creating an istance of the generator theta = np.array([20,10,0.5,-0.3]) #list of parameters to be given to generator [m1,m2,s1,s2] times = np.linspace(-8,0.02, 100000) #time grid at which waves shall be evaluated h_p, h_c = generator.get_WF(theta, times) #returns amplitude and phase of the wave generator.model_summary() #printing model summary #plotting the wave plt.figure(figsize=(15,8)) plt.title("GW by a BBH with [m1,m2,s1,s2] = "+str(theta), fontsize = 15) plt.plot(times, h_p[0,:], c='k') #plot the plus polarization plt.xlabel("Time (s)", fontsize = 12) plt.ylabel(r"$h_+$", fontsize = 12) axins = inset_axes(plt.gca(), width="70%", height="30%", loc=2, borderpad = 2.) axins.plot(times[times >= -0.2], h_p[0,times >= -0.2], c='k') plt.show()
  The output is:
  ###### Summary for MLGW model ###### Grid size: 3500 Minimum time: 0.7999999999999999 s/M_sun ## Model for Amplitude -  ## Model for Phase - , through a linear transformation, of a wave represented in a dense grid.. The experts performs a polynomial regression (using data augmentation in a basis function expansion). The terms in the polynomial are specified at training time.:
  where m_i and s_i are BH masses and spins, d_L the luminosity distance from the source, i is the inclination angle and phi is a reference phase.. It also compute the gradients of the waveform with respct to the relevant physical paramters.
  - N data as (N,D) np.array. The D features must have one of the following layout:.
  The ML model generates the waves in reduced grid t' = t/M_tot with a fixed number of grid points. With argument t grid is in reduced time domain or true time domain. Furthermore, the plus_cross option allows the user to get phase and amplitude of the wave instead of plus and cross polarizations.
  Method get_grads computes the gradients of the waveform with respect to orbital parameters.
  Installation & documentation
  To install the package:
  pip install mlgw
  It requires numpy, scipy and lalsuite, all available to PyPI.
  This page is intented to present the use of the code only for generating a wave. For more advanced use or for more information, please refer to the code documentation:
  import mlgw help(mlgw) help(mlgw.<module_name>)
  For full source code (and much more) see: <>
  Project details
  Release history Release notifications | RSS feed
  Download files
  Download the file for your platform. If you're not sure which to choose, learn more about installing packages.