From f504be5b36d2bee62ee5565a510799e4db648826 Mon Sep 17 00:00:00 2001 From: Thomas White Date: Thu, 5 Mar 2020 15:52:04 +0100 Subject: partialator: Gracefully handle negative and NaN sigma values Of course, these should never happen. --- src/merge.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/merge.c') diff --git a/src/merge.c b/src/merge.c index 817643ed..d0d5b7d6 100644 --- a/src/merge.c +++ b/src/merge.c @@ -191,10 +191,11 @@ static void run_merge_job(void *vwargs, int cookie) struct reflection_contributions *c; if ( get_partiality(refl) < MIN_PART_MERGE ) continue; + if ( isnan(get_esd_intensity(refl)) ) continue; if ( !wargs->qargs->use_weak || ln_merge ) { - if (get_intensity(refl) < 3.0*get_esd_intensity(refl)) { + if (get_intensity(refl) < 3.0*fabs(get_esd_intensity(refl))) { continue; } -- cgit v1.2.3