Miscellaneous improvements to regiongraph, factorgraph and bipgraph, and finished...
authorJoris Mooij <joris.mooij@tuebingen.mpg.de>
Thu, 8 Apr 2010 10:38:39 +0000 (12:38 +0200)
committerJoris Mooij <joris.mooij@tuebingen.mpg.de>
Thu, 8 Apr 2010 10:38:39 +0000 (12:38 +0200)
commit42aabd5d08e6fcffb0a25346206d0a7e4a348ff6
tree2df4010478dda72c9d13545140385006f13b6167
parentb481d241a771995e516bfcb2f82ddaacd29016ed
Miscellaneous improvements to regiongraph, factorgraph and bipgraph, and finished regiongraph unit tests

* Improved regiongraph.h/cpp:
  - Renamed RegionGraph::calcCountingNumbers() into
    RegionGraph::calcCVMCountingNumbers() and made it protected, because
    exposing it to the world serves no purpose.
  - Added RegionGraph::DAG() accessor which returns a reference to the
    region graph DAG structure (currently implemented as a BipartiteGraph)
  - Made RegionGraph::RecomputeORs(), RegionGraph::RecomputeORs( const VarSet& )
    and RegionGraph::RecomputeOR( size_t ) protected and renamed them by changing
    the "Recompute" into "recompute", because exposing them to the world serves no
    purpose.
  - RegionGraph::WriteToFile( const char* ), RegionGraph::ReadFromFile( const char * )
    and RegionGraph::printDot( std::ostream& ) incorrectly called their respective
    FactorGraph ancestor methods; this has been corrected by letting them throw a
    NOT_IMPLEMENTED exception.
  - Changed the way a RegionGraph is streamed to an std::ostream.
* Improved factorgraph.h/cpp:
  - Deprecated the iterator interface:
    o FactorGraph::iterator typedef
    o FactorGraph::const_iterator typedef
    o FactorGraph::begin() members
    o FactorGraph::end() members
  - Deprecated FactorGraph::factor(size_t) which offered write access to a factor
    because using this functionality in the descendant RegionGraph is dangerous,
    as the outer regions are not automatically recomputed.
* Improved bipgraph.h/cpp:
  - Added operator<<( std::ostream&, const BipartiteGraph& )
21 files changed:
ChangeLog
Makefile
README
include/dai/bipgraph.h
include/dai/doc.h
include/dai/factorgraph.h
include/dai/graph.h
include/dai/hak.h
include/dai/regiongraph.h
include/dai/var.h
include/dai/weightedgraph.h
src/bbp.cpp
src/bipgraph.cpp
src/factorgraph.cpp
src/jtree.cpp
src/regiongraph.cpp
tests/unit/bipgraph.cpp
tests/unit/clustergraph.cpp
tests/unit/factorgraph.cpp
tests/unit/graph.cpp
tests/unit/regiongraph.cpp