GregorCH / ipet

Interactive Performance Evaluation Tools for Optimization Software
MIT License
26 stars 6 forks source link

Computing better mean integral plots #20

Closed GregorCH closed 7 years ago

GregorCH commented 7 years ago

The current code for plotting mean integrals (ipet/misc/integrals.py) uses a fixed number of equidistant points to compute the average primal and dual gap as a function of time. However, one can do better by

  1. collecting all the histories
  2. storing them in a priority queue sorted by their next point in time when a primal (dual) bound changes
  3. in each step, pop the next smallest point in time history from the queue, and append to the mean integral the new point in time, and the marginal change of the mean function

In this way, one would obtain an "exact" plot of the primal and dual bound histories that is arguably faster than the current method.