Simplify lalinference.bayespputils.Posterior.write_to_file() method
Description
This MR simplifies the named method, mainly to try and minimise the risk of errors. The main thing that this change introduces is a guarantee that if the savetxt
fails, no open file descriptors will linger (numpy.savetxt
takes care of this automatically). This should introduce no functional changes.
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
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
Please provide details on any reviews related to this change and and the associated reviewers.