Skip to content
Snippets Groups Projects

Feat: Optimace CalDB requests

Merged Mikhail Karnevskiy requested to merge feat/update_plotCalDB into master
1 unresolved thread
Files
2
@@ -135,6 +135,26 @@ def recursively_save_dict_contents_to_group(h5file, path, dic):
@@ -135,6 +135,26 @@ def recursively_save_dict_contents_to_group(h5file, path, dic):
raise ValueError('Cannot save %s type.' % type(item))
raise ValueError('Cannot save %s type.' % type(item))
 
def list_runner(*args, **kwargs):
 
"""
 
Combine several lists to list of dictionary or list of lists
 
Each dictionary contain set of elements, one from each list
 
"""
 
 
params = list(map(tuple, args)) * kwargs.get('repeat', 1)
 
possible_params = [[]]
 
for param in params:
 
possible_params = [x + [y] for x in possible_params for y in param]
 
 
names = kwargs.get('names', None)
 
if names:
 
d_possible_params = []
 
for par in possible_params:
 
d_possible_params.append(dict(zip(names, par)))
 
return d_possible_params
 
return possible_params
 
 
def combine_constants(ctimes_a, ctimes_b):
def combine_constants(ctimes_a, ctimes_b):
"""
"""
Combine two numpy arrays of timestamp
Combine two numpy arrays of timestamp
Loading