diff --git a/modules/util/viirs_surfrad.py b/modules/util/viirs_surfrad.py index 13e253312dfa3a185f0c8086da4511b8676e28f3..38e11bb88dd287c4fb33f1aa14cc4a482a851d44 100644 --- a/modules/util/viirs_surfrad.py +++ b/modules/util/viirs_surfrad.py @@ -91,11 +91,12 @@ def process_cld_prob(grd_k): def process_cld_opd(grd_k): keep = np.invert(np.isnan(grd_k)) num_keep = np.sum(keep) - keep_vthin = np.where(keep, grd_k < 0.01, False) - keep_vthik = np.where(keep, grd_k < 150.0, False) - frac_vthin = np.sum(keep_vthin) / num_keep - frac_vthik = np.sum(keep_vthik) / num_keep - if not (frac_vthin >= 0.10 and frac_vthik >= 0.10): + keep_thin = np.where(keep, np.logical_and(grd_k > 0.1, grd_k < 4.0), False) + keep_thik = np.where(keep, np.logical_and(grd_k > 20.0, grd_k < 158.00), False) + frac_thin = np.sum(keep_thin) / num_keep + frac_thik = np.sum(keep_thik) / num_keep + # if not (frac_thin >= 0.10 and frac_thik >= 0.10): + if not (frac_thin >= 0.20): return None grd_k = np.where(np.invert(keep), 0, grd_k) return grd_k