@@ -114,6 +114,30 @@ def put_if_not_present(target_dict, key, value):
114
114
hyperparams = {
115
115
'method' : ['COBYLA' , 'L-BFGS-B' , 'SLSQP' , 'CG' , 'Powell' , 'Nelder-Mead' , 'BFGS' , 'trust-constr' ],
116
116
}
117
+ elif strategy_to_tune .lower () == "diff_evo" :
118
+ hyperparams = {
119
+ 'method' : ["best1bin" , "best1exp" , "rand1exp" , "randtobest1exp" , "best2exp" , "rand2exp" , "randtobest1bin" , "best2bin" , "rand2bin" , "rand1bin" ],
120
+ 'popsize' : [10 , 20 , 30 ],
121
+ 'maxiter' : [50 , 100 , 150 ],
122
+ }
123
+ elif strategy_to_tune .lower () == "basinhopping" :
124
+ hyperparams = {
125
+ 'method' : ["Nelder-Mead" , "Powell" , "CG" , "BFGS" , "L-BFGS-B" , "TNC" , "COBYLA" , "SLSQP" ],
126
+ 'T' : [0.5 , 1.0 , 1.5 ],
127
+ }
128
+ elif strategy_to_tune .lower () == "genetic_algorithm" :
129
+ hyperparams = {
130
+ 'method' : ["single_point" , "two_point" , "uniform" , "disruptive_uniform" ],
131
+ 'popsize' : [10 , 20 , 30 ],
132
+ 'maxiter' : [50 , 100 , 150 ],
133
+ 'mutation_chance' : [5 , 10 , 20 ]
134
+ }
135
+ elif strategy_to_tune .lower () == "mls" :
136
+ hyperparams = {
137
+ 'neighbor' : ["Hamming" , "adjacent" ],
138
+ 'restart' : [True , False ],
139
+ 'randomize' : [True , False ]
140
+ }
117
141
else :
118
142
raise ValueError (f"Invalid argument { strategy_to_tune = } " )
119
143
0 commit comments