diff --git a/modules/deeplearning/cloud_fraction_fcn_abi.py b/modules/deeplearning/cloud_fraction_fcn_abi.py index e72ea4e1e84c0bc9320bf1fd0c4fa8488b0bebc9..f57b79f84c5016668aa4df9dc7d1eed9688c8e96 100644 --- a/modules/deeplearning/cloud_fraction_fcn_abi.py +++ b/modules/deeplearning/cloud_fraction_fcn_abi.py @@ -1,9 +1,9 @@ -import glob import tensorflow as tf from util.plot_cm import confusion_matrix_values from util.setup import logdir, modeldir, now, ancillary_path from util.util import EarlyStop, normalize, denormalize, get_grid_values_all +import glob import os, datetime import numpy as np import pickle @@ -882,6 +882,7 @@ def run_evaluate_static_valid(in_file, out_file, ckpt_dir): cp_sres = get_grid_values_all(h5f, 'super/'+label_param) mean_cp_sres = get_grid_cell_mean(np.expand_dims(cp_sres, axis=0))[0] + cld_frac_truth = get_label_data_5cat(np.expand_dims(cp_sres, axis=0))[0] h5f.close() @@ -901,7 +902,7 @@ def run_evaluate_static_valid(in_file, out_file, ckpt_dir): }) if out_file is not None: - np.save(out_file, (cld_frac_out, bt, refl, cp, lons, lats, mean_cp_sres)) + np.save(out_file, (cld_frac_out, bt, refl, cp, lons, lats, mean_cp_sres, cld_frac_truth)) else: return [cld_frac_out, bt, refl, cp, lons, lats]