From ed37306f7efc0d3323d8bfacc92df1abf519a1dd Mon Sep 17 00:00:00 2001 From: Francesco Pannarale Date: Mon, 23 Sep 2024 11:15:48 +0200 Subject: [PATCH] Fix nansum check in pygrb_efficiency (#4889) --- bin/pygrb/pycbc_pygrb_efficiency | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/pygrb/pycbc_pygrb_efficiency b/bin/pygrb/pycbc_pygrb_efficiency index ebb40b6eda8..da911042250 100644 --- a/bin/pygrb/pycbc_pygrb_efficiency +++ b/bin/pygrb/pycbc_pygrb_efficiency @@ -624,10 +624,10 @@ ax.plot(dist_plot_vals, (fraction_no_mc), 'g-', ax.errorbar(dist_plot_vals, (fraction_no_mc), yerr=[yerr_low_no_mc, yerr_high_no_mc], c='green') marg_eff = fraction_mc -if not np.nansum(marg_eff) > 0: +if np.nansum(marg_eff) > 0: ax.plot(dist_plot_vals, marg_eff, 'r-', label='Marginalised') ax.errorbar(dist_plot_vals, marg_eff, yerr=[yerr_low, yerr_high], c='red') -if not np.nansum(red_efficiency) > 0: +if np.nansum(red_efficiency) > 0: ax.plot(dist_plot_vals, red_efficiency, 'm-', label='Inc. counting errors') ax.set_ylim([0, 1])