Skip to content

Update lalpulsar_spec_coherence for potentially missing SFTs

Evan Goetz requested to merge evan-goetz/lalsuite:fix-coherence-sfts into master

Description

This MR fixes an issue in lalpulsar_spec_coherence where we may encounter times that the channel B SFTs may not exist for part or all of the interval in question. When there are no SFTs, the code exits early, as desired. However, if part of the SFTs do exist, then there is a potential issue that the loop will fail when trying to take a catalog slice of the channel B SFTs and no SFT is in the catalog for the loading of SFTs.

This MR adds more error checking to the fscanutils.c function extract_one_sft(). It also changes the spec_coherence.c call to the function for the B channel so that it is an XLAL_TRY. When an SFT is failed to be found, it moves on to the next time, as desired.

API Changes and Justification

Backwards Compatible Changes

  • This change does not modify any class/function/struct/type definitions in a public C header file or any Python class/function definitions
  • This change adds new classes/functions/structs/types to a public C header file or Python module

Backwards Incompatible Changes

  • This change modifies an existing class/function/struct/type definition in a public C header file or Python module
  • This change removes an existing class/function/struct/type from a public C header file or Python module

If any of the Backwards Incompatible check boxes are ticked please provide a justification why this change is necessary and why it needs to be done in a backwards incompatible way.

Review Status

This code should be fully backwards compatible and only fixes a minor issue when part of the channel B SFTs are available. @david-keitel or @karl-wette should be able to review this. CC @ansel-neunzert in case they want to comment as well.

Merge request reports

Loading