dingo-gw / dingo

Dingo: Deep inference for gravitational-wave observations
MIT License
55 stars 18 forks source link

Checking for nans in dingo_pipe PSD generation #203

Closed nihargupte-ph closed 1 year ago

nihargupte-ph commented 1 year ago

Currently, the PSD routine used in dingo pipe is determined by Bilby's DataGeneration. However, occasionally for events in O3 (e.g. GW190517) there will be nans in the data stream. We would still like to analyze these events, so we roll back the PSD segment until it does not contain nans. This is done in dingo.gw.data.data_download.download_psd. This PR adds a flag "--shift-segment-for-psd-generation-if-nan" which if True will use the dingo routinte when Nans are detected in the PSD.

The one part I'm a bit unhappy with is the logging since calling download_psd has some print statements which get outputted to stdout when they should be outputted to stderr.

TODO: update documentation