<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On 9 January 2018 at 13:48, Eric Larson <<a href="mailto:larson.eric.d@gmail.com">larson.eric.d@gmail.com</a>> wrote:<br>>><br>>> If you can use `__iter__` instead of `__next__` in your DifferentialEvolutionSolver class I think you can avoid this problem with something along the lines of:<br>><br>> class DifferentialEvolutionSolver(object):<br>> ...<br>> def __iter__(self):<br>> with Parallel(...) ...:<br>> for it in ...:<br>> yield it<br>><br>> As for the map problem I don't know, but it's probably worth asking the `joblib` people if there is a suitable solution or workaround.<br><br></div><div class="gmail_quote">In the scheme of things I'd prefer to retain the use of `__next__`, see <a href="https://github.com/scipy/scipy/pull/6923">https://github.com/scipy/scipy/pull/6923</a> for the direction of where I think things are headed.</div>
</div></div>