Uploaded image for project: 'OptaPlanner'
  1. OptaPlanner
  2. PLANNER-592

A unionMoveSelector with cacheType STEP or PHASE ignores fixedProbabilityWeight of child moveSelectors

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • None
    • 6.4.0.Final
    • optaplanner-core
    • NEW
    • NEW

      Presume we have a solver config like this:

      <unionMoveSelector>
        <cacheType>STEP</cacheType>
        <changeMoveSelector>
          <fixedProbabilityWeight>2</fixedProbabilityWeight
        </changeMoveSelector>
        <swapMoveSelector>
          <fixedProbabilityWeight>1</fixedProbabilityWeight>
        </swapMoveSelector>
      </unionMoveSelector>
      

      If there are 300 changeMoves and 7000 swapMoves, you'd still expect that for every 3 moves you select, there's 2 changeMoves and 1 swapMoves, due to the fixedProbabilityWeight lines.

      But that's not the case, it completely ignores that (so it should either fail fast on that or respect it), and gives you a 3/73 chance to select a change move and 70/73 chance to select a swap move.

            Unassigned Unassigned
            gdesmet@redhat.com Geoffrey De Smet (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: