14 Jan
2017
14 Jan
'17
6:08 p.m.
Jacob Stevenson a écrit :
I also give a big +1 to exposing the individual steps in the algorithm. However I echo Evgeni in that treating it as an iterable `for step in solver:` is a bit unintuitive and I prefer the more straightforward `solver.make_a_single_step_then_pause()`. For what it's worth the underlying solver in basinhopping uses this mechanism, although it's not exposed publicly.
for i in range(niter): new_global_min = bh.one_cycle()
See my answer to Evgeni's point; it's implemented as a `__next__` method.
If we expose this functionality in differential_evolution we could do the same in basinhopping using whatever common syntax is agreed upon
That'd be nice, indeed.