Uploaded image for project: 'Commons Math'
  1. Commons Math
  2. MATH-1658

ConvergenceChecker should implement OptimizationData

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 4.0-beta1
    • None
    • legacy
    • None
    • Easy

    Description

      It is a bit peculiar that with BaseOptimizer, ConvergenceChecker can be passed only in constructor.

      It should be possible to change ConvergenceChecker at any other time.

      Further it is a bit strange that the constructor do not accept other OptimizationData.

      In my use cases, I need to create an optimizer once with complex OptimizationData and reuse it many time with very few changes (including changing the ConvergenceChecker).

      So, I suggest that

      • ConvergenceChecker implements OptimizationData.
      • protected BaseOptimizer(ConvergenceChecker<PAIR> checker) is replaced by protected BaseOptimizer(OptimizationData... optData) 

      Doing so is compatible with existing code and provide much more flexibility.

      Attachments

        1. MATH-1658-ConvergenceChecker-implements-OptimizationData.patch
          3 kB
          François Laferrière
        2. MATH-1658.patch
          2 kB
          Gilles Sadowski

        Activity

          People

            Unassigned Unassigned
            flaferriere François Laferrière
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: