![]() |
aGrUM 2.3.2
a C++ library for (probabilistic) graphical models
|
This is an abstract class used to tune search strategies in the gspan algorithm. More...
#include <agrum/PRM/gspan/searchStrategy.h>
Public Member Functions | |
Constructor and destructor. | |
| SearchStrategy () | |
| Default constructor. | |
| SearchStrategy (const SearchStrategy< GUM_SCALAR > &from) | |
| Copy constructor. | |
| virtual | ~SearchStrategy () |
| Destructor. | |
| SearchStrategy< GUM_SCALAR > & | operator= (const SearchStrategy< GUM_SCALAR > &from) |
| Copy operator. | |
Search methods. | |
| void | setTree (DFSTree< GUM_SCALAR > *tree) |
| virtual bool | accept_root (const Pattern *r)=0 |
| virtual bool | accept_growth (const Pattern *parent, const Pattern *child, const EdgeGrowth< GUM_SCALAR > &growth)=0 |
| virtual bool | operator() (LabelData *i, LabelData *j)=0 |
| virtual bool | operator() (Pattern *i, Pattern *j)=0 |
Protected Member Functions | |
| double | computeCost_ (const Pattern &p) |
Protected Attributes | |
| DFSTree< GUM_SCALAR > * | tree_ |
This is an abstract class used to tune search strategies in the gspan algorithm.
Since GSpan uses a DFS to expand the search tree, this class works as a stack regarding adding and removing informations about the growths.
Definition at line 81 of file searchStrategy.h.
| INLINE gum::prm::gspan::SearchStrategy< GUM_SCALAR >::SearchStrategy | ( | ) |
Default constructor.
Definition at line 214 of file searchStrategy_tpl.h.
References SearchStrategy(), and tree_.
Referenced by gum::prm::gspan::FrequenceSearch< GUM_SCALAR >::FrequenceSearch(), gum::prm::gspan::FrequenceSearch< GUM_SCALAR >::FrequenceSearch(), SearchStrategy(), SearchStrategy(), gum::prm::gspan::StrictSearch< GUM_SCALAR >::StrictSearch(), gum::prm::gspan::StrictSearch< GUM_SCALAR >::StrictSearch(), gum::prm::gspan::TreeWidthSearch< GUM_SCALAR >::TreeWidthSearch(), gum::prm::gspan::TreeWidthSearch< GUM_SCALAR >::TreeWidthSearch(), ~SearchStrategy(), and operator=().
| INLINE gum::prm::gspan::SearchStrategy< GUM_SCALAR >::SearchStrategy | ( | const SearchStrategy< GUM_SCALAR > & | from | ) |
Copy constructor.
Definition at line 220 of file searchStrategy_tpl.h.
References SearchStrategy(), and tree_.
|
virtual |
Destructor.
Definition at line 226 of file searchStrategy_tpl.h.
References SearchStrategy().
|
pure virtual |
|
pure virtual |
|
protected |
Definition at line 56 of file searchStrategy_tpl.h.
References gum::SequenceImplementation< Key, Gen >::exists(), gum::SequenceImplementation< Key, Gen >::insert(), and tree_.
Referenced by gum::prm::gspan::StrictSearch< GUM_SCALAR >::_compute_costs_(), and gum::prm::gspan::TreeWidthSearch< GUM_SCALAR >::cost().
|
pure virtual |
|
pure virtual |
| INLINE SearchStrategy< GUM_SCALAR > & gum::prm::gspan::SearchStrategy< GUM_SCALAR >::operator= | ( | const SearchStrategy< GUM_SCALAR > & | from | ) |
Copy operator.
Definition at line 232 of file searchStrategy_tpl.h.
References SearchStrategy(), and tree_.
| INLINE void gum::prm::gspan::SearchStrategy< GUM_SCALAR >::setTree | ( | DFSTree< GUM_SCALAR > * | tree | ) |
Definition at line 238 of file searchStrategy_tpl.h.
References tree_.
|
protected |
Definition at line 120 of file searchStrategy.h.
Referenced by SearchStrategy(), SearchStrategy(), gum::prm::gspan::StrictSearch< GUM_SCALAR >::_compute_costs_(), gum::prm::gspan::FrequenceSearch< GUM_SCALAR >::accept_growth(), gum::prm::gspan::StrictSearch< GUM_SCALAR >::accept_growth(), gum::prm::gspan::FrequenceSearch< GUM_SCALAR >::accept_root(), gum::prm::gspan::StrictSearch< GUM_SCALAR >::accept_root(), computeCost_(), gum::prm::gspan::FrequenceSearch< GUM_SCALAR >::operator()(), gum::prm::gspan::FrequenceSearch< GUM_SCALAR >::operator()(), gum::prm::gspan::StrictSearch< GUM_SCALAR >::operator()(), gum::prm::gspan::StrictSearch< GUM_SCALAR >::operator()(), operator=(), and setTree().