If you face this issue working with LsqFit.jl
it might help to specify the initial values p0
as floating point numbers, instead of Int
.
This was wrong in my example:
p0 = [100, 2000, 4000]
This cured the issue:
p0 = [100.0, 2000.0, 4000.0]