I have a case of a function which must be run with a large number of parameter types
# generic function with named parameters
def genericFn(X, y, a_fn ='t', o_fn ='a', l_fn='b', dim=2):
...
return accuracy
I have a list of parameter types
a_fns = ['t', 's', 'r', 'l']
o_fns = ['s', 'a']
l_fns = ['m', 'h', 'l', 'b', 'k', 'p']
How can I pass every possible combination of the functions to the pool
with concurrent.futures.ProcessPoolExecutor() as executor:
results_list = executor.map(genericFn, (combinations of named parameters))
Remember that you need to adapt examples to your needs. You could use something like this: