Skip to content

CFSv2: use XLALReadMultiTimestampsFilesConstrained

Description

  • fixes #506 (closed)
  • provides expected behaviour when combining --timestampsFiles --minStartTime --maxStartTime
  • The actual fix is just swapping in the more modern constrained loading function, but to make the code more readable, I also moved the uvars-to-constraints-struct lines above it, and removed two spurious blank lines that made it more difficult to see what were logical blocks.

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

Simple test case, with these 4 timestamps in a file:

1000000000
1000001800
1000003600
1000005400

->

lalpulsar_ComputeFstatistic_v2 --Alpha=0 --Delta=0 --FreqBand=0.0 --Freq=50  --countTemplates --injectSqrtSX=1 --IFOs H1 --timestampsFiles timestamps_H1.txt
lalpulsar_ComputeFstatistic_v2 --Alpha=0 --Delta=0 --FreqBand=0.0 --Freq=50  --countTemplates --injectSqrtSX=1 --IFOs H1 --timestampsFiles timestamps_H1.txt --minStartTime=1000000000 --maxStartTime=1000003600

On the current release/master version, both commands return %% Loaded SFTs: [ H1:4 ]. With the patch, the second goes down to %% Loaded SFTs: [ H1:2 ] as it should.

I don't know if we want to further inflate the already large zoo of CFSv2 test scripts, or just leave it at that one-off test.

Merge request reports