source: trunk/Cbc/scripts/parse_cbc.awk @ 1540

Last change on this file since 1540 was 1540, checked in by tkr, 9 years ago

Adding scripts for running becnhmark tests

File size: 1.4 KB
Line 
1#!/usr/bin/awk -f
2#* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
3#*                                                                           *
4#*            This file is part of the test engine for MIPLIB2010            *
5#*                                                                           *
6#* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
7
8# set all solver specific data:
9#  solver ["?"]
10#  solverversion ["?"]
11#  lps ["none"]
12#  lpsversion ["-"]
13#  bbnodes [0]
14#  db [-infty]
15#  pb [+infty]
16#  aborted [1]
17#  timeout [0]
18
19# The solver name
20BEGIN {
21   solver = "CBC";
22   gap = 0;
23}
24
25# The solver version
26/^Version:/ {
27   version = $2;
28}
29
30/^Revision Number:/ {
31   revision = $3;
32   solverversion = version "-" revision
33}
34
35# The results
36/^Result/ {
37   if ($3 == "Optimal"){
38      if ($7 == "gap"){
39         gap = 1;
40      }else{
41         gap = 0
42      }
43      aborted = 0;
44      timeout = 0;
45   }
46   if ($5 == "infeasible"){
47      pb = +infty;
48      db = +infty;
49      aborted = 0;
50      timeout = 0;
51   }else if ($5 == "unbounded"){
52      pb = -infty;
53      db = -infty;
54      aborted = 0;
55      timeout = 0;
56   }else if ($3 == "Stopped"){
57      if ($5 == "time"){
58         timeout = 1;
59         aborted = 0;
60      }
61   }else if ($3 == "Difficulties"){
62      aborted = 1
63   }
64}
65
66/^Objective value:/ {
67   pb = $3;
68   if (!gap){
69      db = pb;
70   }
71}
72
73/^Lower bound:/ {
74   db = $3;
75}
76
77/^Enumerated nodes:/ {
78   bbnodes = $3
79}
80
Note: See TracBrowser for help on using the repository browser.