diff --git a/modules/aeolus/aeolus_amv.py b/modules/aeolus/aeolus_amv.py index 29a5e099995297bef6006edae2a4b69f1cf7e056..96ac7c3778f9dc4066a66bd5fc221c07a4363295 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())