-
-
Notifications
You must be signed in to change notification settings - Fork 5.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BUG: Fixed broken dogbox trust-region radius update #5556
Conversation
How hard would it be to add a test for this? |
Not very difficult, I can include one rather small problem. I guess you recommend me to do it) btw: I hope to send a narrative documentation update for least squares in a few days. |
Evgeni, a test is here. I noticed one thing: when using finite diff. Jacobian estimation, we have to set |
The fix looks right, but the test doesn't seem to test it: if I cherry-pick nmayorov@71d6c5b on top of master, |
@ev-br hmm, I deliberately tested for this before sending. Sorry, I will recheck. |
Are you sure? When I remove
|
Rrright. OK, when I run the tests with the file name, it fails indeed.
Can you please check this Nikolay? |
There's no `config.add_data_dir('tests')` in _lsq/setup.py, so the test
files don't end up installed.
|
The numpy test runner also doesn't seem to run the tests on |
I always used |
@pv I'm struggling to get nose to test Maybe just put all tests in |
I don't understand distutils (or setuptools, whichever is this), but this change seems to do it:
|
With this, I get the number of tests run in
|
So basically you added the line |
Nope, that was a stale build :-(. |
Probably amount to a bug in I'd just move the tests to |
Thanks, Pauli. Evgeni are you OK with the decision to move tests? |
Skipping |
Sounds like the best way out indeed. |
W.r.t. the question of |
I modified tests of reflective transformation as not to crash on numpy 1.6.2, it doesn't affect real performance as optimization code works with float arrays (the issue was dtype mismatch which isn't handled by numpy 1.6.2) So I think it's ready to be merged. The error on TravisCI is not related to the changes in this PR. |
Indeed, CI errors seem unrelated and should be fixed by gh-5572.
Looks like these would be easy to fix. |
@ev-br I changed those tests. |
Great, thanks Nikolay! |
BUG: Fixed broken dogbox trust-region radius update
I was solving some least-squares problems and bumped into quite a bug, which blocks dogbox solver progress.
Explanation: if the trial step was unsuccessful then trust-region radius is updated as
Delta = 0.25 * step_h_norm
, but in dogbox trust regions are rectangular, thusstep_h_norm
must be computed with infinity norm, otherwiseDelta
may not shrink and we get into infinite loop.Please merge this fix asap.