Giter VIP home page Giter VIP logo

Comments (2)

filokot avatar filokot commented on August 23, 2024 3

An observation:

The error comes from the estimation method parameter est in the simple_1param.py:
image

est represents a single unknown (C) and therefore contains a single-key dict with a 1D list value <= est.json. Correspondingly, the variable b (=list of tuples of length est) of the MODESTGA object (ga_parallel.py, line 305) becomes a list of single tuple element and is passed as parameter bounds to the method minimize defined in ga.py

image

Therefore, len(bounds) => (len(bounds) = 1) => 1-1/len(bounds) => division by zero in line 199 of ga.py

image

Keeping two variables unknown (C and R1) instead of one in simple_1param.py leads to the list of bounds containing two elements => 1 - 1/len(bounds) = 1 - 1/2 = 0.5 which "fixes" the problem (optimizer finishes with no error message).
image

Therefore, to enable estimation of a single unknown parameter in ModestPy, it seems appropriate to replace len(bounds) by len(bounds)+0.01 in the denominator or something else of this sort. Optimizer finishes with no error message.

image

image

from modest-py.

krzysztofarendt avatar krzysztofarendt commented on August 23, 2024

Thanks for tracking down the error. I fixed it in modestga: krzysztofarendt/modestga@24f69e6

You need to update the package: pip install -U modestga

from modest-py.

Related Issues (20)

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.