[Coin-lpsolver] Sbb: Use of setTestForDuplicateIndex and CoinMessages
Jean-Sebastien Roy
js at jeannot.org
Thu Apr 1 17:23:00 EST 2004
John J Forrest wrote:
> The reason ClpMessage was being called so much was that in
> OsiClpSolverInterface::resolve a "lightweight" copy of fixed model is
> made as it seemed safer as then hints could be used on this created
> model. Unhappily this lightweight copy did have message creation and
> this can be an overhead on very small models. As far as I can see it
> does no harm to use the fixed model. This does improve times on small
> models significantly. If anyone does notice any adverse effects
> please tell me.
>
> For setTestForDuplicateIndex I have effectively removed it when called
> from fullset. This is perfectly safe as there is no way a dense
> vector can have duplicates! However I only see a small improvement.
> Can you tell me if my changes help more for you?
I re-ran a set of test, and the results varies quite a lot between
platforms (Linux/FreeBSD or Solaris).
On FreeBSD, during the profiling, the difference is considerable: With
the test for duplicate index, CoinPackedVector::CoinPackedVector(int,
double const *, bool) takes 31.9 % of the total time (1902 seconds).
Without, it takes 0.3 %, of 1198 seconds.
But the profilng results seems quite unreliable since once the profiling
is removed, the difference between runs is only 10% (a bit more on Solaris).
I updated the source incorporating your changes and ran Sbb on a small
problem :
Before : 40s
After : 21s
That's really nice. Many thanks !
js
More information about the Clp
mailing list