java - IncrementalScore produces unfeasible solution in Optaplanner -
java - IncrementalScore produces unfeasible solution in Optaplanner -
i still using optaplanner optimize chained planning problem similar vehicleroutingexample. planning entities have planning variable planning entity. scores hardsoftscores.
i have initialized incrementalscore solve runtime-problem, isn’t working right , wasn’t able find reason why. (with debugging, system.out… ect. ...)
the problem solver doesn’t create feasible solution of testing dataset using incrementalscore. know possible find feasible solution because solver created 1 easyscore.
the optimal solution created easyscore gives me score: (0hard/-151763soft) when incrementalscore solving unusual values.
the score given solver.getbestsolution().getscore() (-25hard/-207111soft), when instantiate incrementalscorecalculator , allow calculate score of bestsolution, values (-34hard/-207111soft). checked solution , found out, first values wrong, sec ones “correct” (but not feasible).
does has thought error is? or there other ways find reason?
in manual see chapter "5.3.6. invalid score detection" find out when easy , incremental score calculation go out of sync.
<environmentmode>full_assert</environmentmode> ... <scoredirectorfactory> <scoredefinitiontype>...</scoredefinitiontype> <incrementalscorecalculatorclass>...incrementalscorecalculator</incrementalscorecalculatorclass> <assertionscoredirectorfactory> <easyscorecalculatorclass>...easyscorecalculator</easyscorecalculatorclass> </assertionscoredirectorfactory> </scoredirectorfactory>
then comment out constraint type's in both implementation 0 in on constraint that's implemented differently. looks it's 1 of hard constraints that's calculating invalidly.
java optimization optaplanner scoring drools-planner
Comments
Post a Comment