Skip to content
Snippets Groups Projects
Commit 961c1a58 authored by tomrink's avatar tomrink
Browse files

snapshot...

parent 91161a05
No related branches found
No related tags found
No related merge requests found
......@@ -239,9 +239,9 @@ def create_file2(filename, raob_to_amv_dct, raob_dct, amv_files):
def run_best_fit_all(amv_dir, source, product_dir, product, raob_path, gfs_path, full_domain=False):
amv_files = get_datasource(amv_dir, 10, source)
prd_files = get_datasource(product_dir, 10, product)
gfs_files = get_datasource(gfs_path, 10, 'GFS')
amv_files = get_datasource(amv_dir, source)
prd_files = get_datasource(product_dir, product)
gfs_files = get_datasource(gfs_path, 'GFS')
raob_files = glob.glob(raob_path+'raob_soundings*.cdf')
out_list = []
......
......@@ -52,8 +52,8 @@ class Files:
class RAOBfiles(Files):
def __init__(selfs, files_path, file_time_span, pattern):
super().__init__(files_path, file_time_span, pattern)
def __init__(selfs, files_path):
super().__init__(files_path, 10, 'raob_soundings*.cdf')
def get_datetime(self, pathname):
filename = os.path.split(pathname)[1]
......@@ -63,8 +63,8 @@ class RAOBfiles(Files):
class GFSfiles(Files):
def __init__(self, files_path, file_time_span, pattern):
super().__init__(files_path, file_time_span, pattern)
def __init__(self, files_path):
super().__init__(files_path, 10, 'gfs*.h5')
def get_datetime(self, pathname):
filename = os.path.split(pathname)[1]
......@@ -330,7 +330,7 @@ class CarrStereo(AMVFiles):
return dto
def get_datasource(files_path, file_time_span, source, band='14'):
def get_datasource(files_path, source, file_time_span=10, band='14'):
if source == 'OPS':
return OPS(files_path, file_time_span, band=band)
elif source == 'FMWK':
......@@ -344,6 +344,8 @@ def get_datasource(files_path, file_time_span, source, band='14'):
elif source == 'OPS_CLD_PHASE':
return OpsCloudPhase(files_path, file_time_span)
elif source == 'GFS':
return GFSfiles(files_path, file_time_span, 'gfs*.h5')
return GFSfiles(files_path)
elif source == 'RAOB':
return RAOBfiles(files_path)
else:
raise GenericException('Unknown data source type')
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment