Skip to content
Snippets Groups Projects
Commit 7a17e48c authored by tomrink's avatar tomrink
Browse files

snapshot...

parent a4b404b7
No related branches found
No related tags found
No related merge requests found
......@@ -2,27 +2,12 @@ from util.geos_nav import get_navigation
from util.setup_cloud_fraction import model_path
from aeolus.datasource import CLAVRx
import os
from deeplearning.cloud_fraction_fcn_abi import SRCNN, run_evaluate_static, run_evaluate_static_full_disk
from deeplearning.cloud_fraction_fcn_abi import SRCNN
from util.util import get_cartopy_crs, write_cld_frac_file_nc4
import numpy as np
def infer_cloud_fraction(clvrx_path, output_dir, full_disk=True):
ckpt_dir_s = os.listdir(model_path)
ckpt_dir = model_path + ckpt_dir_s[0]
clvrx_ds = CLAVRx(clvrx_path)
for fname, t_start, t_stop in clvrx_ds:
dto = clvrx_ds.get_datetime(fname)
clvrx_str_time = dto.strftime('%Y-%m-%d_%H:%M')
out_file = output_dir + 'cloud_fraction_' + clvrx_str_time
if full_disk:
run_evaluate_static_full_disk(fname, out_file, ckpt_dir)
else:
run_evaluate_static(fname, out_file, ckpt_dir)
def infer_cloud_fraction_new(clvrx_path, output_dir, full_disk=True, satellite='GOES16', domain='FD'):
def infer_cloud_fraction(clvrx_path, output_dir, full_disk=True, satellite='GOES16', domain='FD'):
# location of the trained model
ckpt_dir_s = os.listdir(model_path)
ckpt_dir = model_path + ckpt_dir_s[0]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment