I am using scipy.optimize.curve_fit()
in an iterative way.
My problem is that when ever it is unable to fit the parameters the whole program (and thus the iteration) stops, this is the error it gives:
RuntimeError: Optimal parameters not found: Number of calls to function has reached maxfev = 800.
I understand that why it has been unable to fit. My problem is that is there any way I can write the program in Python 3.2.2 that will ignore such occurrences and just continue?