From 31576548a30fffac2fec69066dd0984c3fae7217 Mon Sep 17 00:00:00 2001 From: tomrink <rink@ssec.wisc.edu> Date: Wed, 2 Dec 2020 12:46:57 -0600 Subject: [PATCH] snapshot... --- modules/aeolus/aeolus_amv.py | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/modules/aeolus/aeolus_amv.py b/modules/aeolus/aeolus_amv.py index 29a5e099..96ac7c37 100644 --- a/modules/aeolus/aeolus_amv.py +++ b/modules/aeolus/aeolus_amv.py @@ -161,16 +161,15 @@ class CarrStereo(AMVFiles): # raob_dict: time -> profiles # amv_files_path: directory containing AMVs, '/home/user/amvdir/' # return dict: raob -> tuple (amv_lon, amv_lat, amv_pres, amv_spd, amv_dir) -def match_amvs_to_raobs(raob_dict, raob_time, amv_files): +def match_amvs_to_raobs(raob_dict, raob_time, amv_files, filepath=None): nav = amv_files.get_navigation() amv_params = amv_files.get_parameters() match_dict = {} - #fname, ftime, f_idx = amv_files.get_file_containing_time(raob_time) - fname = '/Users/tomrink/data/OR_ABI-L2-DMWF-M6C14_G16_s20201190000156_e20201190009464_c20201190023107.nc' - # fname = '/Users/tomrink/data/OR_ABI-L2-DMWF-M6C14_G16_s20201191200158_e20201191209466_c20201191223041.nc' + if filepath is None: + filepath, ftime, f_idx = amv_files.get_file_containing_time(raob_time) - ds = Dataset(fname) + ds = Dataset(filepath) amv_lons = ds[amv_files.lon_name][:].data amv_lats = ds[amv_files.lat_name][:].data @@ -327,10 +326,6 @@ def create_file2(filename, raob_to_amv_dct, raob_dct, amv_files): rootgrp.close() -def bulk_stats(filename): - pass - - def analyze2(raob_to_amv_dct, raob_dct): keys = list(raob_to_amv_dct.keys()) -- GitLab