Skip to content
Snippets Groups Projects
Commit 2533dbb2 authored by rink's avatar rink
Browse files

snapshot..

parent 168bd385
Branches
No related tags found
No related merge requests found
......@@ -141,7 +141,7 @@ def get_file_containing_time(timestamp, files_path, dto_func, file_time_span):
# imports the S4 NOAA output
# filename: full path as a string, '/home/user/filename'
# returns a dict: time -> list of profiles (a profile is a list of levels)
def get_aeolus_time_dict(filename, lon360=False):
def get_aeolus_time_dict(filename, lon360=False, do_sort=True):
time_dict = {}
with open(filename) as file:
......@@ -199,6 +199,17 @@ def get_aeolus_time_dict(filename, lon360=False):
file.close()
if do_sort:
keys = np.array(list(time_dict.keys()))
keys.sort()
keys = keys.tolist()
sorted_time_dict = {}
for key in keys:
sorted_time_dict[key] = time_dict.get(key)
time_dict = sorted_time_dict
return time_dict
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment