Add another exception to catch in `plot_with_data`
Status | Pipeline | Created by | Stages | Actions |
---|---|---|---|---|
Passed 00:09:45
| Stage: test |
Download artifacts
No artifacts found |
Maintenance will be performed on git.ligo.org, containers.ligo.org, and docs.ligo.org on Tuesday 22 April 2025 starting at approximately 9am PDT. It is expected to take around 30 minutes and there will be several periods of downtime throughout the maintenance. Please address any comments, concerns, or questions to the helpdesk. This maintenance will be upgrading the GitLab database in order to be ready for the migration.
Currently, the plot_with_data
function tries to check if results.posterior.log_likelihood
exists using np.isnan
within a try...except...
block, for which the exception only catches AttributeError
s. If using, for example, the emcee sampler the results.posterior.log_likelihood
values in the pandas DataFrame default to being filled with None
-types, as the log_likelihood
values are not set. When these are tested using np.isnan
it results in a TypeError
, which is not caught by the except
block and the function does not work. This MR allows the except
to also catch a TypeError
.
It would be good to set the log_likelihood
values if using emcee
from the lnprobability
values that it can return (but that's for another issue...)
Status | Pipeline | Created by | Stages | Actions |
---|---|---|---|---|
Passed 00:09:45
| Stage: test |
Download artifacts
No artifacts found |