From 90117f5bd99cd18ac2e722678e38354a22e79906 Mon Sep 17 00:00:00 2001
From: tomrink <rink@ssec.wisc.edu>
Date: Wed, 27 Sep 2023 15:35:27 -0500
Subject: [PATCH] snapshot...

---
 modules/util/util.py | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/modules/util/util.py b/modules/util/util.py
index 7cd3cb7c..b64ca2f2 100644
--- a/modules/util/util.py
+++ b/modules/util/util.py
@@ -1478,7 +1478,7 @@ def write_icing_file_nc4_viirs(clvrx_str_time, output_dir, preds_dct, probs_dct,
     rootgrp.close()
 
 
-def write_cld_frac_file_nc4(clvrx_str_time, outfile_name, cloud_fraction,
+def write_cld_prods_file_nc4(clvrx_str_time, outfile_name, cloud_fraction, cloud_frac_opd,
                             x, y, elems, lines, satellite='GOES16', domain='CONUS',
                             has_time=False):
 
@@ -1512,6 +1512,14 @@ def write_cld_frac_file_nc4(clvrx_str_time, outfile_name, cloud_fraction,
         cloud_fraction = cloud_fraction.reshape((1, y.shape[0], x.shape[0]))
     cld_frac_ds[:, ] = cloud_fraction
 
+    cld_frac_opd_ds = rootgrp.createVariable('cldy_fraciion_opd', 'f4', var_dim_list)
+    cld_frac_opd_ds.setncattr('coordinates', geo_coords)
+    cld_frac_opd_ds.setncattr('grid_mapping', 'Projection')
+    cld_frac_opd_ds.setncattr('missing', -1)
+    if has_time:
+        cloud_frac_opd = cloud_frac_opd.reshape((1, y.shape[0], x.shape[0]))
+    cld_frac_opd_ds[:, ] = cloud_frac_opd
+
     cf_nav_dct = get_cf_nav_parameters(satellite, domain)
 
     if satellite == 'H08':
-- 
GitLab