Lalsim automated spin evolution and averaged fits for final mass and spin, peak luminosity, and radiated energy in bayespputils
Description
These changes automate the computation of the final mass and spin, radiated energy, and peak luminosity for binary black hole coalescences using averaged fits as part of cbcBayesPostProc (code changes in bayespputils) and gives spin evolution as an option in the PE pipeline--the current version of bayespputils uses older fits for these quantities with no spin evolution and no contribution to the final spin from in-plane spins. The names of these quantities now have new suffixes, *_evol
for computations with evolved spins (including aligned spin cases, where the spin evolution is trivial--the identity--and is thus performed in all cases), and *_nonevol
for computations in precessing cases without evolved spins. The spins are evolved up to the Schwarzschild ISCO frequency, so the sample names for the evolved spin angles have the suffix *_isco
. Additionally, the af_*
samples now give the magnitude of the final spin, while the afz_*
samples give the projection of the final spin along the ISCO orbital angular momentum, which for aligned-spin systems gives the same physical meaning as the signed quantity that was previously called af. Finally, since these fits and spin evolution are only applicable to binary black holes, they are not applied if the PE run includes tidal parameters.
These computations were previously implemented in a stand-alone post-postprocessing code to obtain results for the GWTC-1 paper. However, this new code uses the LALSimulation PN spin evolution instead of the much slower Python implementation used previously. We have chosen to use the TaylorT5 spin evolution with spinO = 7--see here for tests of the accuracy of the final mass and spin with various versions of the spin evolution. We also now set the quadrant of phi12_isco
correctly (it was previously just the quadrant given by numpy.arccos). Since the LALSimulation PN spin evolution allows for evolution to lower frequencies, we no longer check that the initial frequency is below the ISCO frequency.
In addition to the changes to bayespputils to implement the newer fits and work with the evolved spins when present, there are changes to lalinference_pipe_utils to allow for spin evolution as an option as part of the PE pipeline, and a new script, evolve_spins_and_append_samples.py, which performs the spin evolution and puts the evolved spin samples into the posterior samples HDF5 file.
There is also some reshuffling of code between lalinference_nest2pos.py and hdf5.py, to make a function accessible to evolve_spins_and_append_samples.py, as well as small changes to the packaging due to the additional script.
We have tested the changes by performing full parameter estimation runs (using lalinference_pipe) in various cases, linked from this wiki page. (The check that the spin evolution and fits are not applied if tidal samples are present still has to be re-run, due to Condor issues. However, this inadvertently let us test lalinference_nest2pos's checks on the LALInference version used to create the samples, since we edited this part of the code--see /home/anuradha.gupta/spin_evolution_test/pe_runs_160719/tidal_ns_run/run/log/merge-118195898-0.err on CIT.) We have cross-checked the spin evolution and application of the fits against a separate Python script and found that they agree to many digits, as expected. This is documented on the aforementioned wiki page.
API Changes and Justification
Backwards Compatible Changes
-
This change introduces no API changes -
This change adds new API calls
Backwards Incompatible Changes
-
This change modifies an existing API -
This change removes an existing API
Review Status
The stand-alone code this is based on was reviewed by David Keitel here.