ejeschke / ginga

The Ginga astronomical FITS file viewer
BSD 3-Clause "New" or "Revised" License
122 stars 77 forks source link

RuntimeWarning in IQCalc (Pick plugin) #144

Closed pllim closed 8 years ago

pllim commented 9 years ago

Sometimes, Pick gives the warning below to the screen (not Ginga's log file):

.../scipy/optimize/minpack.py:421: RuntimeWarning: Number of calls to function has reached maxfev = 800.
  warnings.warn(errors[info][0], RuntimeWarning)

This most likely comes from this line below in IQCalc.calc_fwhm() method in util/iqcalc.py when the data is not well-behaved:

 p1, success = optimize.leastsq(errfunc, p0[:], args=(X, Y))
pllim commented 8 years ago

Fixed in #247