GithubHelp home page GithubHelp logo

scipy_issue_powell's Introduction

Powell failure reproducer

python powell_fails.py

Explanation

The take-home is that, for a simple least-squares problem, and ordinary-looking data, for a particular starting value, fmin_powell stops on a not-minimum value and claims success, where other optimizers do find the minimum, as does the Octave implementation.

Here is the output from the reproducer:

LS inter: 2.114798570871842
LS slope: 0.5088641205763367
LS SSE error: 1.0674470960898728

BGFS minimization:
Optimization terminated successfully.
         Current function value: 1.067447
         Iterations: 3
         Function evaluations: 15
         Gradient evaluations: 5
[2.11480099 0.50886336]

Powell minimization:
Optimization terminated successfully.
         Current function value: 1.074363
         Iterations: 6
         Function evaluations: 152
[2.22069108 0.47457665]

As you can see, the Powell result has a higher sum of squared error, different parameters, and claims success.  I get this for Scipy 1.10.1 on Mac M2, Intel, and Ubuntu 22.04 amd64.

scipy_issue_powell's People

Contributors

christophschranz avatar matthew-brett avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.