Added "logdomain" property to BP.
authorJoris Mooij <jorism@marvin.jorismooij.nl>
Tue, 9 Sep 2008 09:42:19 +0000 (11:42 +0200)
committerJoris Mooij <jorism@marvin.jorismooij.nl>
Tue, 9 Sep 2008 09:42:19 +0000 (11:42 +0200)
This is a boolean that controls whether calculations are done in the
log-domain or in the linear domain; doing calculations in the log-domain
may help if the numerical range of a double is too small.

ChangeLog
Makefile
include/dai/bp.h
src/bp.cpp
src/mr.cpp
tests/aliases.conf
tests/testall
tests/testfast.out

index 42406f4..4afe39a 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,9 +1,24 @@
 libDAI-0.2.2 (2008-??-??)
 -------------------------
+
+* Pervasive change of BipartiteGraph implementation (based on an idea by
+  Giuseppe Passino). BipartiteGraph no longer stores the node properties (former
+  _V1 and _V2), nor does it store a dense adjacency matrix anymore, nor an edge
+  list. Instead, it stores the graph structure as lists of neighboring nodes.
+  This yields a significant memory/speed improvement for large factor graphs, and
+  is more elegant as well. Iterating over neighbors is made easy by using
+  boost::foreach.
+* Improved index.h (merged from SVN head):
+  - Renamed Index -> IndexFor
+  - Added some .reserve()'s to IndexFor methods which yields a 
+    25% speedup of testregression
+  - Replaced multind by Permute
+  - Added MultiFor
+  - Added State
 * Moved everything into namespace "dai"
 * Renamed DEBUG to DAI_DEBUG to avoid conflicts
-* Contributions by ???:
+* Added conditional compilation of inference methods
+* Contributions by Peter Gober:
   - Renamed variable _N in mr.* for compatibility with g++ under cygwin
 * Contributions by Giuseppe Passino:
   - removed "using namespace std;" from header files - bad practice
@@ -16,14 +31,38 @@ libDAI-0.2.2 (2008-??-??)
     o  added methods takeExp, takeLog, takeLog0 for transformation in-place
     o  explicit constructor (prevents implicit conversion from size_t to TProb)
     o  added operator+,+=,-,-=, with argument T (for calculations in log-scale)
-* Contributions by Christian Wojek, resulting in vast speed and memory improvements
-  for large factor graphs:
-  - Sparse implementation of nodes->edge conversion table _E12ind in bipgraph.h
+  - Added "logdomain" property to BP, a boolean that controls whether 
+    calculations are done in the log-domain or in the linear domain;
+    doing calculations in the log-domain may help if the numerical range
+    of a double is too small.
+* Contributions by Christian Wojek:
   - New FactorGraph constructor that constructs from given ranges of factors
     and variables
-  - Optimization of FactorGraph constructors
-* FactorGraph constructors no longer check for short loops and for
-  negative entries. Also, the normtype is now Prob::NORMPROB by default.
+  - Optimization of FactorGraph constructors using tr1::unordered_map.
+* FactorGraph constructors no longer check for short loops (huge speed
+  increase for large factor graphs), nor for negative entries. Also, the 
+  normtype is now Prob::NORMPROB by default.
+* Small optimization in Diffs
+* Interface changes:
+  - VarSet::
+    stateSpace() -> VarSet::states()
+  - FactorGraph::
+    delta(const Var &) -> delta(size_t)
+    Delta(const Var &) -> Delta(size_t)
+    makeCavity(const Var &) -> makeCavity(size_t)
+    removed MakeFactorCavity(size_t)
+    removed ExactMarginal(const VarSet &)
+    removed ExactlogZ()
+    moved isConnected() to BipartiteGraph
+    vars() -> vars
+    factors() -> factors
+  - RegionGraph::
+    nr_ORs() -> nrORs()
+    nr_IRs() -> nrIRs()
+    ORs() -> ORs
+    IRs() -> IRs
+  - *::Regenerate() -> *::create()
+  - Renamed Index -> IndexFor
 
 
 libDAI-0.2.1 (2008-05-26)
index b87d177..9cfc91a 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -42,7 +42,7 @@ BOOSTFLAGS = -lboost_program_options
 CC = g++
 
 # Flags for the C++ compiler
-CCFLAGS = -Wall -W -Wextra -fpic -I./include -Llib -O3 #-pg #-static -DVERBOSE
+CCFLAGS = -Wall -W -Wextra -fpic -I./include -Llib -O3 #-pg #-static #-DVERBOSE
 ifdef DEBUG
 CCFLAGS := $(CCFLAGS) -g -DDAI_DEBUG
 else
index b2d78a4..9bb1b51 100644 (file)
@@ -43,18 +43,19 @@ class BP : public DAIAlgFG {
         };
 
         std::vector<std::vector<EdgeProp> > edges;
+        bool logDomain;
 
     public:
         ENUM4(UpdateType,SEQFIX,SEQRND,SEQMAX,PARALL)
         UpdateType Updates() const { return GetPropertyAs<UpdateType>("updates"); }
 
         // default constructor
-        BP() : DAIAlgFG() {};
+        BP() : DAIAlgFG(), edges(), logDomain(false) {};
         // copy constructor
-        BP(const BP & x) : DAIAlgFG(x), edges(x.edges) {};
+        BP(const BP & x) : DAIAlgFG(x), edges(x.edges), logDomain(x.logDomain) {};
         BP* clone() const { return new BP(*this); }
         // construct BP object from FactorGraph
-        BP(const FactorGraph & fg, const Properties &opts) : DAIAlgFG(fg, opts) {
+        BP(const FactorGraph & fg, const Properties &opts) : DAIAlgFG(fg, opts), edges(), logDomain(false) {
             assert( checkProperties() );
             create();
         }
@@ -63,6 +64,7 @@ class BP : public DAIAlgFG {
             if(this!=&x) {
                 DAIAlgFG::operator=(x);
                 edges = x.edges;
+                logDomain = x.logDomain;
             }
             return *this;
         }
index 1d60bf4..655944e 100644 (file)
@@ -48,11 +48,15 @@ bool BP::checkProperties() {
         return false;
     if (!HasProperty("verbose") )
         return false;
+    if (!HasProperty("logdomain") )
+        return false;
     
     ConvertPropertyTo<double>("tol");
     ConvertPropertyTo<size_t>("maxiter");
     ConvertPropertyTo<size_t>("verbose");
     ConvertPropertyTo<UpdateType>("updates");
+    ConvertPropertyTo<bool>("logdomain");
+    logDomain = GetPropertyAs<bool>("logdomain");
 
     return true;
 }
@@ -85,8 +89,13 @@ void BP::init() {
     assert( checkProperties() );
     for( size_t i = 0; i < nrVars(); ++i ) {
         foreach( const Neighbor &I, nbV(i) ) {
-            message( i, I.iter ).fill( 1.0 );
-            newMessage( i, I.iter ).fill( 1.0 );
+            if( logDomain ) {
+                message( i, I.iter ).fill( 0.0 );
+                newMessage( i, I.iter ).fill( 0.0 );
+            } else {
+                message( i, I.iter ).fill( 1.0 );
+                newMessage( i, I.iter ).fill( 1.0 );
+            }
         }
     }
 }
@@ -122,6 +131,8 @@ void BP::calcNewMessage( size_t i, size_t _I ) {
 */
     
     Prob prod( factor(I).p() );
+    if( logDomain ) 
+        prod.takeLog();
 
     // Calculate product of incoming messages and factor I
     foreach( const Neighbor &j, nbF(I) ) {
@@ -131,17 +142,27 @@ void BP::calcNewMessage( size_t i, size_t _I ) {
             const ind_t & ind = index(j, _I);
 
             // prod_j will be the product of messages coming into j
-            Prob prod_j( var(j).states() ); 
-            foreach( const Neighbor &J, nbV(j) ) {
-                if( J != I )   // for all J in nb(j) \ I 
-                    prod_j *= message( j, J.iter );
-            }
+            Prob prod_j( var(j).states(), logDomain ? 0.0 : 1.0 ); 
+            foreach( const Neighbor &J, nbV(j) )
+                if( J != I ) { // for all J in nb(j) \ I 
+                    if( logDomain )
+                        prod_j += message( j, J.iter );
+                    else
+                        prod_j *= message( j, J.iter );
+                }
 
             // multiply prod with prod_j
             for( size_t r = 0; r < prod.size(); ++r )
-                prod[r] *= prod_j[ind[r]];
+                if( logDomain )
+                    prod[r] += prod_j[ind[r]];
+                else
+                    prod[r] *= prod_j[ind[r]];
         }
     }
+    if( logDomain ) {
+        prod -= prod.max();
+        prod.takeExp();
+    }
 
     // Marginalize onto i
     Prob marg( var(i).states(), 0.0 );
@@ -152,7 +173,10 @@ void BP::calcNewMessage( size_t i, size_t _I ) {
     marg.normalize( _normtype );
     
     // Store result
-    newMessage(i,_I) = marg;
+    if( logDomain )
+        newMessage(i,_I) = marg.log();
+    else
+        newMessage(i,_I) = marg;
 }
 
 
@@ -270,9 +294,16 @@ double BP::run() {
 
 
 Factor BP::beliefV( size_t i ) const {
-    Prob prod( var(i).states() ); 
+    Prob prod( var(i).states(), logDomain ? 0.0 : 1.0 ); 
     foreach( const Neighbor &I, nbV(i) )
-        prod *= newMessage( i, I.iter );
+        if( logDomain )
+            prod += newMessage( i, I.iter );
+        else
+            prod *= newMessage( i, I.iter );
+    if( logDomain ) {
+        prod -= prod.max();
+        prod.takeExp();
+    }
 
     prod.normalize( Prob::NORMPROB );
     return( Factor( var(i), prod ) );
@@ -310,6 +341,8 @@ Factor BP::belief( const VarSet &ns ) const {
 
 Factor BP::beliefF (size_t I) const {
     Prob prod( factor(I).p() );
+    if( logDomain )
+        prod.takeLog();
 
     foreach( const Neighbor &j, nbF(I) ) {
         size_t _I = j.dual;
@@ -317,15 +350,28 @@ Factor BP::beliefF (size_t I) const {
         const ind_t & ind = index(j, _I);
 
         // prod_j will be the product of messages coming into j
-        Prob prod_j( var(j).states() ); 
+        Prob prod_j( var(j).states(), logDomain ? 0.0 : 1.0 ); 
         foreach( const Neighbor &J, nbV(j) ) {
-            if( J != I )   // for all J in nb(j) \ I 
-                prod_j *= newMessage( j, J.iter );
+            if( J != I ) { // for all J in nb(j) \ I 
+                if( logDomain )
+                    prod_j += newMessage( j, J.iter );
+                else
+                    prod_j *= newMessage( j, J.iter );
+            }
         }
 
         // multiply prod with prod_j
-        for( size_t r = 0; r < prod.size(); ++r )
-            prod[r] *= prod_j[ind[r]];
+        for( size_t r = 0; r < prod.size(); ++r ) {
+            if( logDomain )
+                prod[r] += prod_j[ind[r]];
+            else
+                prod[r] *= prod_j[ind[r]];
+        }
+    }
+
+    if( logDomain ) {
+        prod -= prod.max();
+        prod.takeExp();
     }
 
     Factor result( factor(I).vars(), prod );
@@ -366,7 +412,7 @@ void BP::init( const VarSet &ns ) {
     for( VarSet::const_iterator n = ns.begin(); n != ns.end(); ++n ) {
         size_t ni = findVar( *n );
         foreach( const Neighbor &I, nbV( ni ) )
-            message( ni, I.iter ).fill( 1.0 );
+            message( ni, I.iter ).fill( logDomain ? 0.0 : 1.0 );
     }
 }
 
index cf80165..ce0774b 100644 (file)
@@ -491,7 +491,7 @@ void MR::init_cor() {
     for( size_t i = 0; i < nrVars(); i++ ) {
         vector<Factor> pairq;
         if( Inits() == InitType::CLAMPING ) {
-            BP bpcav(*this, Properties()("updates",string("SEQMAX"))("tol", string("1e-9"))("maxiter", string("1000UL"))("verbose", string("0UL")));
+            BP bpcav(*this, Properties()("updates",string("SEQMAX"))("tol", string("1e-9"))("maxiter", string("1000UL"))("verbose", string("0UL"))("logdomain", string("0")));
             bpcav.makeCavity( i );
             pairq = calcPairBeliefs( bpcav, delta(i), false );
         } else if( Inits() == InitType::EXACT ) {
index 9c84db6..f749c2a 100644 (file)
@@ -1,7 +1,11 @@
-BP_SEQFIX:                      BP[updates=SEQFIX,tol=1e-9,maxiter=10000,verbose=0]
-BP_SEQRND:                      BP[updates=SEQRND,tol=1e-9,maxiter=10000,verbose=0]
-BP_SEQMAX:                      BP[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0]
-BP_PARALL:                      BP[updates=PARALL,tol=1e-9,maxiter=10000,verbose=0]
+BP_SEQFIX:                      BP[updates=SEQFIX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0]
+BP_SEQRND:                      BP[updates=SEQRND,tol=1e-9,maxiter=10000,verbose=0,logdomain=0]
+BP_SEQMAX:                      BP[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0]
+BP_PARALL:                      BP[updates=PARALL,tol=1e-9,maxiter=10000,verbose=0,logdomain=0]
+BP_SEQFIX_LOG:                  BP[updates=SEQFIX,tol=1e-9,maxiter=10000,verbose=0,logdomain=1]
+BP_SEQRND_LOG:                  BP[updates=SEQRND,tol=1e-9,maxiter=10000,verbose=0,logdomain=1]
+BP_SEQMAX_LOG:                  BP[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=1]
+BP_PARALL_LOG:                  BP[updates=PARALL,tol=1e-9,maxiter=10000,verbose=0,logdomain=1]
 
 JTREE_HUGIN:                    JTREE[updates=HUGIN,verbose=0]
 JTREE_SHSH:                     JTREE[updates=SHSH,verbose=0]
@@ -19,23 +23,23 @@ MR_CLAMPING_LINEAR:             MR[updates=LINEAR,inits=CLAMPING,verbose=0,tol=1
 MR_EXACT_FULL:                  MR[updates=FULL,inits=EXACT,verbose=0,tol=1e-9]
 MR_EXACT_LINEAR:                MR[updates=LINEAR,inits=EXACT,verbose=0,tol=1e-9]
 
-LCBP_FULLCAVin_SEQFIX:          LC[cavity=FULL,reinit=1,updates=SEQFIX,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
-LCBP_FULLCAVin_SEQRND:          LC[cavity=FULL,reinit=1,updates=SEQRND,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
-LCBP_FULLCAVin_NONE:            LC[cavity=FULL,reinit=1,updates=SEQFIX,maxiter=0,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
-LCBP_FULLCAV_SEQFIX:            LC[cavity=FULL,reinit=0,updates=SEQFIX,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
-LCBP_FULLCAV_SEQRND:            LC[cavity=FULL,reinit=0,updates=SEQRND,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
-LCBP_FULLCAV_NONE:              LC[cavity=FULL,reinit=0,updates=SEQFIX,maxiter=0,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
-LCBP_PAIRCAVin_SEQFIX:          LC[cavity=PAIR,reinit=1,updates=SEQFIX,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
-LCBP_PAIRCAVin_SEQRND:          LC[cavity=PAIR,reinit=1,updates=SEQRND,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
-LCBP_PAIRCAVin_NONE:            LC[cavity=PAIR,reinit=1,updates=SEQFIX,maxiter=0,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
-LCBP_PAIRCAV_SEQFIX:            LC[cavity=PAIR,reinit=0,updates=SEQFIX,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
-LCBP_PAIRCAV_SEQRND:            LC[cavity=PAIR,reinit=0,updates=SEQRND,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
-LCBP_PAIRCAV_NONE:              LC[cavity=PAIR,reinit=0,updates=SEQFIX,maxiter=0,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
+LCBP_FULLCAVin_SEQFIX:          LC[cavity=FULL,reinit=1,updates=SEQFIX,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0],tol=1e-9,verbose=0]
+LCBP_FULLCAVin_SEQRND:          LC[cavity=FULL,reinit=1,updates=SEQRND,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0],tol=1e-9,verbose=0]
+LCBP_FULLCAVin_NONE:            LC[cavity=FULL,reinit=1,updates=SEQFIX,maxiter=0,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0],tol=1e-9,verbose=0]
+LCBP_FULLCAV_SEQFIX:            LC[cavity=FULL,reinit=0,updates=SEQFIX,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0],tol=1e-9,verbose=0]
+LCBP_FULLCAV_SEQRND:            LC[cavity=FULL,reinit=0,updates=SEQRND,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0],tol=1e-9,verbose=0]
+LCBP_FULLCAV_NONE:              LC[cavity=FULL,reinit=0,updates=SEQFIX,maxiter=0,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0],tol=1e-9,verbose=0]
+LCBP_PAIRCAVin_SEQFIX:          LC[cavity=PAIR,reinit=1,updates=SEQFIX,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0],tol=1e-9,verbose=0]
+LCBP_PAIRCAVin_SEQRND:          LC[cavity=PAIR,reinit=1,updates=SEQRND,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0],tol=1e-9,verbose=0]
+LCBP_PAIRCAVin_NONE:            LC[cavity=PAIR,reinit=1,updates=SEQFIX,maxiter=0,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0],tol=1e-9,verbose=0]
+LCBP_PAIRCAV_SEQFIX:            LC[cavity=PAIR,reinit=0,updates=SEQFIX,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0],tol=1e-9,verbose=0]
+LCBP_PAIRCAV_SEQRND:            LC[cavity=PAIR,reinit=0,updates=SEQRND,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0],tol=1e-9,verbose=0]
+LCBP_PAIRCAV_NONE:              LC[cavity=PAIR,reinit=0,updates=SEQFIX,maxiter=0,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0],tol=1e-9,verbose=0]
 LCBP_UNICAV_SEQFIX:             LC[cavity=UNIFORM,updates=SEQFIX,maxiter=10000,tol=1e-9,verbose=0,cavaiopts=[],cavainame=NONE]
 LCBP_UNICAV_SEQRND:             LC[cavity=UNIFORM,updates=SEQRND,maxiter=10000,tol=1e-9,verbose=0,cavaiopts=[],cavainame=NONE]
-LCBP_PAIR2CAV_SEQFIX:           LC[cavity=PAIR2,reinit=0,updates=SEQFIX,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
-LCBP_PAIRINTCAV_SEQFIX:         LC[cavity=PAIRINT,reinit=0,updates=SEQFIX,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
-LCBP_PAIRCUMCAV_SEQFIX:         LC[cavity=PAIRCUM,reinit=0,updates=SEQFIX,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
+LCBP_PAIR2CAV_SEQFIX:           LC[cavity=PAIR2,reinit=0,updates=SEQFIX,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0],tol=1e-9,verbose=0]
+LCBP_PAIRINTCAV_SEQFIX:         LC[cavity=PAIRINT,reinit=0,updates=SEQFIX,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0],tol=1e-9,verbose=0]
+LCBP_PAIRCUMCAV_SEQFIX:         LC[cavity=PAIRCUM,reinit=0,updates=SEQFIX,maxiter=10000,cavainame=BP,cavaiopts=[updates=SEQMAX,tol=1e-9,maxiter=10000,verbose=0,logdomain=0],tol=1e-9,verbose=0]
 LCTREEEP:                       LC[cavity=FULL,reinit=1,updates=SEQFIX,maxiter=10000,cavainame=TREEEP,cavaiopts=[type=ORG,tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
 LCMF:                           LC[cavity=FULL,reinit=1,updates=SEQFIX,maxiter=10000,cavainame=MF,cavaiopts=[tol=1e-9,maxiter=10000,verbose=0],tol=1e-9,verbose=0]
 
index a428afb..2cf6099 100755 (executable)
@@ -1,2 +1,2 @@
 #!/bin/bash
-./test --aliases aliases.conf --filename $1 --methods JTREE_HUGIN JTREE_SHSH BP_SEQFIX BP_SEQRND BP_SEQMAX BP_PARALL MF_SEQRND TREEEP TREEEPWC GBP_MIN GBP_DELTA GBP_LOOP3 GBP_LOOP4 HAK_MIN HAK_DELTA HAK_LOOP3 HAK_LOOP4 MR_RESPPROP_FULL MR_CLAMPING_FULL MR_EXACT_FULL MR_RESPPROP_LINEAR MR_CLAMPING_LINEAR MR_EXACT_LINEAR LCBP_FULLCAV_SEQFIX LCBP_FULLCAVin_SEQFIX LCBP_FULLCAV_SEQRND LCBP_FULLCAVin_SEQRND LCBP_FULLCAV_NONE LCBP_FULLCAVin_NONE LCBP_PAIRCAV_SEQFIX LCBP_PAIRCAVin_SEQFIX LCBP_PAIRCAV_SEQRND LCBP_PAIRCAVin_SEQRND LCBP_PAIRCAV_NONE LCBP_PAIRCAVin_NONE LCBP_UNICAV_SEQFIX LCBP_UNICAV_SEQRND
+./test --aliases aliases.conf --filename $1 --methods JTREE_HUGIN JTREE_SHSH BP_SEQFIX BP_SEQRND BP_SEQMAX BP_PARALL BP_SEQFIX_LOG BP_SEQRND_LOG BP_SEQMAX_LOG BP_PARALL_LOG MF_SEQRND TREEEP TREEEPWC GBP_MIN GBP_DELTA GBP_LOOP3 GBP_LOOP4 HAK_MIN HAK_DELTA HAK_LOOP3 HAK_LOOP4 MR_RESPPROP_FULL MR_CLAMPING_FULL MR_EXACT_FULL MR_RESPPROP_LINEAR MR_CLAMPING_LINEAR MR_EXACT_LINEAR LCBP_FULLCAV_SEQFIX LCBP_FULLCAVin_SEQFIX LCBP_FULLCAV_SEQRND LCBP_FULLCAVin_SEQRND LCBP_FULLCAV_NONE LCBP_FULLCAVin_NONE LCBP_PAIRCAV_SEQFIX LCBP_PAIRCAVin_SEQFIX LCBP_PAIRCAV_SEQRND LCBP_PAIRCAVin_SEQRND LCBP_PAIRCAV_NONE LCBP_PAIRCAVin_NONE LCBP_UNICAV_SEQFIX LCBP_UNICAV_SEQRND
index 47f053c..ac36f23 100644 (file)
@@ -1,39 +1,43 @@
 # testfast.fg
 # METHOD                                      CLOCKS     MAX ERROR   AVG ERROR  LOGZ ERROR     MAXDIFF
-JTREE_HUGIN                                        0    
-JTREE_SHSH                                         1     1.000e-09   1.000e-09   1.000e-09   1.000e-09
+JTREE_HUGIN                                        2    
+JTREE_SHSH                                         2     1.000e-09   1.000e-09   1.000e-09   1.000e-09
 BP_SEQFIX                                          1     9.483e-02   3.078e-02   1.737e-02   1.000e-09
-BP_SEQRND                                          0     9.483e-02   3.078e-02   1.737e-02   1.000e-09
+BP_SEQRND                                          1     9.483e-02   3.078e-02   1.737e-02   1.000e-09
 BP_SEQMAX                                          0     9.483e-02   3.078e-02   1.737e-02   1.000e-09
-BP_PARALL                                          0     9.483e-02   3.078e-02   1.737e-02   1.000e-09
-MF_SEQRND                                          4     3.607e-01   1.904e-01  -9.409e-02   1.000e-09
-TREEEP                                             7     3.268e-02   8.023e-03   6.340e-04   1.000e-09
-TREEEPWC                                           6     2.356e-02   1.026e-02   4.876e-03   1.000e-09
+BP_PARALL                                          1     9.483e-02   3.078e-02   1.737e-02   1.000e-09
+BP_SEQFIX_LOG                                      1     9.483e-02   3.078e-02   1.737e-02   1.000e-09
+BP_SEQRND_LOG                                      0     9.483e-02   3.078e-02   1.737e-02   1.000e-09
+BP_SEQMAX_LOG                                      1     9.483e-02   3.078e-02   1.737e-02   1.000e-09
+BP_PARALL_LOG                                      1     9.483e-02   3.078e-02   1.737e-02   1.000e-09
+MF_SEQRND                                          3     3.607e-01   1.904e-01  -9.409e-02   1.000e-09
+TREEEP                                             5     3.268e-02   8.023e-03   6.340e-04   1.000e-09
+TREEEPWC                                           4     2.356e-02   1.026e-02   4.876e-03   1.000e-09
 GBP_MIN                                            2     9.483e-02   3.078e-02   1.737e-02   1.000e-09
-GBP_DELTA                                         13     6.291e-01   3.350e-01  -3.303e-01   1.000e-09
+GBP_DELTA                                          8     6.291e-01   3.350e-01  -3.303e-01   1.000e-09
 GBP_LOOP3                                          2     9.483e-02   3.078e-02   1.737e-02   1.000e-09
-GBP_LOOP4                                          8     7.893e-01   3.569e-01  -3.781e-01   1.000e-09
-HAK_MIN                                           34     9.483e-02   3.078e-02   1.737e-02   1.000e-09
-HAK_DELTA                                        638     3.684e-01   1.892e-01   9.675e-01   1.000e-09
-HAK_LOOP3                                         39     9.483e-02   3.078e-02   1.737e-02   1.000e-09
-HAK_LOOP4                                       1051     4.970e-03   1.486e-03  -2.503e-04   1.000e-09
-MR_RESPPROP_FULL                                  35     1.676e-02   4.933e-03         nan   1.000e-09
-MR_CLAMPING_FULL                                  21     8.359e-03   2.508e-03         nan   1.000e-09
-MR_EXACT_FULL                                     22     3.527e-03   1.038e-03         nan   1.000e-09
-MR_RESPPROP_LINEAR                                35     1.932e-02   5.506e-03         nan   1.000e-09
-MR_CLAMPING_LINEAR                                20     1.089e-02   3.076e-03         nan   1.000e-09
-MR_EXACT_LINEAR                                   23     5.617e-03   1.742e-03         nan   1.000e-09
-LCBP_FULLCAV_SEQFIX                               34     1.225e-03   5.589e-04         nan   1.000e-09
-LCBP_FULLCAVin_SEQFIX                             36     1.225e-03   5.589e-04         nan   1.000e-09
-LCBP_FULLCAV_SEQRND                               34     1.225e-03   5.589e-04         nan   1.000e-09
-LCBP_FULLCAVin_SEQRND                             35     1.225e-03   5.589e-04         nan   1.000e-09
-LCBP_FULLCAV_NONE                                 26     1.318e-02   2.644e-03         nan   1.000e+00
-LCBP_FULLCAVin_NONE                               27     1.318e-02   2.644e-03         nan   1.000e+00
-LCBP_PAIRCAV_SEQFIX                               30     1.564e-02   5.284e-03         nan   1.000e-09
-LCBP_PAIRCAVin_SEQFIX                             31     1.564e-02   5.284e-03         nan   1.000e-09
-LCBP_PAIRCAV_SEQRND                               28     1.564e-02   5.284e-03         nan   1.000e-09
-LCBP_PAIRCAVin_SEQRND                             28     1.564e-02   5.284e-03         nan   1.000e-09
+GBP_LOOP4                                          6     7.893e-01   3.569e-01  -3.781e-01   1.000e-09
+HAK_MIN                                           27     9.483e-02   3.078e-02   1.737e-02   1.000e-09
+HAK_DELTA                                        394     3.684e-01   1.892e-01   9.675e-01   1.000e-09
+HAK_LOOP3                                         27     9.483e-02   3.078e-02   1.737e-02   1.000e-09
+HAK_LOOP4                                        726     4.970e-03   1.486e-03  -2.503e-04   1.000e-09
+MR_RESPPROP_FULL                                  36     1.676e-02   4.933e-03         nan   1.000e-09
+MR_CLAMPING_FULL                                  22     8.359e-03   2.508e-03         nan   1.000e-09
+MR_EXACT_FULL                                     20     3.527e-03   1.038e-03         nan   1.000e-09
+MR_RESPPROP_LINEAR                                37     1.932e-02   5.506e-03         nan   1.000e-09
+MR_CLAMPING_LINEAR                                21     1.089e-02   3.076e-03         nan   1.000e-09
+MR_EXACT_LINEAR                                   20     5.617e-03   1.742e-03         nan   1.000e-09
+LCBP_FULLCAV_SEQFIX                               31     1.225e-03   5.589e-04         nan   1.000e-09
+LCBP_FULLCAVin_SEQFIX                             33     1.225e-03   5.589e-04         nan   1.000e-09
+LCBP_FULLCAV_SEQRND                               30     1.225e-03   5.589e-04         nan   1.000e-09
+LCBP_FULLCAVin_SEQRND                             33     1.225e-03   5.589e-04         nan   1.000e-09
+LCBP_FULLCAV_NONE                                 25     1.318e-02   2.644e-03         nan   1.000e+00
+LCBP_FULLCAVin_NONE                               26     1.318e-02   2.644e-03         nan   1.000e+00
+LCBP_PAIRCAV_SEQFIX                               27     1.564e-02   5.284e-03         nan   1.000e-09
+LCBP_PAIRCAVin_SEQFIX                             27     1.564e-02   5.284e-03         nan   1.000e-09
+LCBP_PAIRCAV_SEQRND                               25     1.564e-02   5.284e-03         nan   1.000e-09
+LCBP_PAIRCAVin_SEQRND                             26     1.564e-02   5.284e-03         nan   1.000e-09
 LCBP_PAIRCAV_NONE                                 19     1.869e-01   6.816e-02         nan   1.000e+00
-LCBP_PAIRCAVin_NONE                               21     1.869e-01   6.816e-02         nan   1.000e+00
-LCBP_UNICAV_SEQFIX                                10     9.483e-02   3.078e-02         nan   1.000e-09
-LCBP_UNICAV_SEQRND                                10     9.483e-02   3.078e-02         nan   1.000e-09
+LCBP_PAIRCAVin_NONE                               20     1.869e-01   6.816e-02         nan   1.000e+00
+LCBP_UNICAV_SEQFIX                                 6     9.483e-02   3.078e-02         nan   1.000e-09
+LCBP_UNICAV_SEQRND                                 8     9.483e-02   3.078e-02         nan   1.000e-09