gwBOB.mismatch_utils module

gwBOB.mismatch_utils.find_best_mismatch_padded(padded_t_model, padded_h_model, padded_t_nr, padded_h_nr, nr_peak_time_batch, t0, tf, coarse_window, coarse_t_num, fine_window, fine_t_num, integration_points)[source]

JAX compatible mismatch search function. Finds the best time shift between two time series using the trapz integration method.

Parameters:
  • padded_t_model (array) – The time array of the model data.

  • padded_h_model (complex array) – The complex-valued time series of the model data.

  • padded_t_nr (array) – The time array of the NR data.

  • padded_h_nr (complex array) – The complex-valued time series of the NR data.

  • nr_peak_time_batch (array) – The peak time of the NR data.

  • t0 (float) – The relative start time of the integration window.

  • tf (float) – The relative end time of the integration window.

  • coarse_window (float) – The coarse window size.

  • coarse_t_num (int) – The number of coarse integration points.

  • fine_window (float) – The fine window size.

  • fine_t_num (int) – The number of fine integration points.

  • integration_points (int) – The number of integration points.

gwBOB.mismatch_utils.mismatch_trapz(h1_padded, t1_padded, h2_padded, t2_padded, t_peak_nr, t0_relative, tf_relative, integration_points)[source]

JAX compatible mismatch function. Calculates the mismatch between two time series using the trapz integration method.

Parameters:
  • h1_padded (complex array) – The complex-valued time series of the model data.

  • t1_padded (array) – The time array of the model data.

  • h2_padded (complex array) – The complex-valued time series of the NR data.

  • t2_padded (array) – The time array of the NR data.

  • t_peak_nr (float) – The peak time of the NR data.

  • t0_relative (float) – The relative start time of the integration window.

  • tf_relative (float) – The relative end time of the integration window.

  • integration_points (int) – The number of integration points.

Returns:

mismatch – The mismatch between the two time series.

Return type:

float

gwBOB.mismatch_utils.time_shift(h_complex, t, t_shift)[source]

JAX compatible time shift function. Shifts the time series by a given amount.

Parameters:
  • h_complex (complex array) – The complex-valued time series to be shifted.

  • t (array) – The time array.

  • t_shift (float) – The amount to shift the time series by.

Returns:

h_shifted – The shifted time series.

Return type:

complex array