How was max_nfev = 2000 * (nvarys + 1)
chosen?
#963
-
Seems like it is ancient history now, but how was |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
@jagerber48 yeah. The "200*(n_variables+1)" in When Since the whole concept is "use Python instead of Fortran to do non-linear-least-squares fitting", we favor "easy/friendly for novices" over raw performance and don't "give up early to avoid using too many expensive CPU cycles and expect the programmer/analyst to fix initial values, recompile, and start over". FWIW, I have a low opinion of |
Beta Was this translation helpful? Give feedback.
@jagerber48 yeah. The "200*(n_variables+1)" in
leastsq
is probably taken directly fromlmdif1.f
(https://netlib.org/minpack/lmdif1.f) the "simplified wrapper with some sane defaults" around the reallmdif.f
from the MINPACK library. Which was written in 1980. I don't know what that means to you (I'm listening to Remain in Light), but that code was no doubt being tested on high-end PDP-11s with clock speeds well over 1 MHz and as much as 4 MB "core memory", that were meant to be time-shared with multiple users.When
max_nfev
is reached, the fit stops and reports failure. So, "200*(n_variables+1)" is probably a reasonable estimate of "if it takes that many evaluations, something could be wr…