This PR seems to have started leading me towards stateful optimizers that can be paused/resumed in the middle. While this of course sounds excellent, the changes required to adapt master (and also #12 ) are quite substantial.
Also, not sure if it's the best implementing the state in a OOP way. I'd like to do this in the data-oriented fashion, but this requires more thinking, since I don't have the experience. Also I'm not sure it's worth it and might result in a better interface / faster / more robust implementation.
Implements https://github.com/to266/optimize/issues/9
Also ran
cargo fmt
on the crate... Will attempt to add this as a requirement for every PR@sebasv if you could have a look if you agree with the implementation?