optimize: Replace FunctionConverge with an interface
Created by: btracey
Right now we only allow a specific kind of function convergence. It seems like this should be replaced with an interface. An extended idea is to pass *Location
and not just f
. If we can figure out how to make this easy, we could possibly wrap FunctionThreshold and GradientThreshold into this (or just FunctionThreshold since it's less common to use).