weecology / macroecotools

Tools for Macroecological Analyses Using Python
Other
9 stars 13 forks source link

RuntimeError, generalized Yule #11

Closed embaldridge closed 9 years ago

embaldridge commented 10 years ago

I'm not sure if this is a problem or not, since it throws an error message back, but it did this on one of the FIA sites, and I thought I should mention it.

Traceback (most recent call last): File "/usr/lib/wingide-101-4.1/src/debug/tserver/_sandbox.py", line 170, in File "/usr/lib/wingide-101-4.1/src/debug/tserver/_sandbox.py", line 117, in model_comparisons File "/usr/local/lib/python2.7/dist-packages/macroecotools-0.2-py2.7.egg/macroeco_distributions/macroeco_distributions.py", line 522, in gen_yule_solver File "/usr/lib/python2.7/dist-packages/scipy/optimize/zeros.py", line 161, in newton raise RuntimeError(msg) RuntimeError: Failed to converge after 500 iterations, value is -5.5026056311e+104

rueuntal commented 10 years ago

Could you please try out the newest version of the module on this site to check if the problem is fixed? Specifically, if the function still print "Failed to converge" for this site?

embaldridge commented 10 years ago

It didn't print "Failed to converge this time". It was the site's fault anyway, I think, one of the abundance values is 2.5.

rueuntal commented 10 years ago

Hmmm, that's a problem for sure, but shouldn't cause the function to fail by itself. Could you post the abundance list of this site?

embaldridge commented 10 years ago

My mistake, it was a site in the Gentry data that had a 2.5. I think the offending site was 1,1,1,1,2,2,2,2,5,5, but my brain is not processing right at the moment, and I didn't take detailed enough notes this time when it was working right.

rueuntal commented 10 years ago

Now the function works as it's supposed to (at least for the given site). Let me know if anything looks suspicious.