MCPcopy Create free account
hub / github.com/davisking/dlib / py_find_min_global2

Function py_find_min_global2

tools/python/src/global_optimization.cpp:216–234  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

214}
215
216py::tuple py_find_min_global2 (
217 py::object f,
218 py::list bound1,
219 py::list bound2,
220 unsigned long num_function_calls,
221 double solver_epsilon = 0
222)
223{
224 DLIB_CASSERT(len(bound1) == len(bound2));
225
226 auto func = [&](const matrix<double,0,1>& x)
227 {
228 return call_func(f, x);
229 };
230
231 auto result = find_min_global(func, list_to_mat(bound1), list_to_mat(bound2), max_function_calls(num_function_calls), solver_epsilon);
232
233 return py::make_tuple(mat_to_list(result.x),result.y);
234}
235
236// ----------------------------------------------------------------------------------------
237

Callers

nothing calls this directly

Calls 7

lenFunction · 0.85
call_funcFunction · 0.85
find_min_globalFunction · 0.85
list_to_matFunction · 0.85
make_tupleFunction · 0.85
mat_to_listFunction · 0.85
max_function_callsClass · 0.50

Tested by

no test coverage detected