dlvhex
2.5.0
|
Template for offline model building of a ModelGraph based on an EvalGraph. More...
#include <include/dlvhex2/OfflineModelBuilder.h>
Data Structures | |
struct | OfflineModelBuildingProperties |
Properties of offline model building. More... | |
Public Types | |
typedef OfflineModelBuilder < EvalGraphT > | Self |
typedef Base::EvalUnit | EvalUnit |
typedef Base::EvalUnitDep | EvalUnitDep |
typedef Base::EvalUnitPropertyBundle | EvalUnitPropertyBundle |
typedef Base::MyModelGraph | MyModelGraph |
typedef Base::Model | Model |
typedef Base::ModelPropertyBundle | ModelPropertyBundle |
typedef Base::OptionalModel | OptionalModel |
typedef MyModelGraph::ModelList | ModelList |
typedef ModelList::const_iterator | ModelListIterator |
typedef boost::optional < ModelListIterator > | OptionalModelListIterator |
Public Member Functions | |
OfflineModelBuilder (ModelBuilderConfig< EvalGraphT > &cfg) | |
Constructor. | |
virtual | ~OfflineModelBuilder () |
Destructor. | |
EvalGraphT & | getEvalGraph () |
Returns the internal evaluation graph. | |
MyModelGraph & | getModelGraph () |
Returns the internal model graph. | |
void | printEvalGraphModelGraph (std::ostream &o) |
Prints both the evaluation and the model graph for debugging purposes. | |
void | printModelBuildingPropertyMap (std::ostream &o) |
Prints the model building properties for debugging purposes. | |
virtual unsigned | buildIModels (EvalUnit u) |
Builds the input models at the given. | |
virtual unsigned | buildOModels (EvalUnit u) |
Builds the output models at the given. | |
virtual unsigned | buildIModelsRecursively (EvalUnit u) |
virtual unsigned | buildOModelsRecursively (EvalUnit u) |
Protected Types | |
typedef OnlineModelBuilder < EvalGraphT > | Base |
typedef boost::vector_property_map < OfflineModelBuildingProperties > | OfflineModelBuildingPropertyMap |
Protected Member Functions | |
virtual OptionalModel | getNextIModel (EvalUnit u) |
Get next input model (projected if projection is configured) at e given unit. | |
Protected Attributes | |
OfflineModelBuildingPropertyMap | offmbp |
Properties of models. | |
boost::optional < CAUAlgorithms::JoinRelevancePropertyMap > | currentjrp |
For each call we need this storage, this is not threadsafe! (but the rest of model building is unlikely to be threadsafe as well). |
Template for offline model building of a ModelGraph based on an EvalGraph.
Definition at line 45 of file OfflineModelBuilder.h.
typedef OnlineModelBuilder<EvalGraphT> OfflineModelBuilder< EvalGraphT >::Base [protected] |
Reimplemented from OnlineModelBuilder< EvalGraphT >.
Definition at line 50 of file OfflineModelBuilder.h.
typedef Base::EvalUnit OfflineModelBuilder< EvalGraphT >::EvalUnit |
Reimplemented from OnlineModelBuilder< EvalGraphT >.
Definition at line 55 of file OfflineModelBuilder.h.
typedef Base::EvalUnitDep OfflineModelBuilder< EvalGraphT >::EvalUnitDep |
Reimplemented from OnlineModelBuilder< EvalGraphT >.
Definition at line 56 of file OfflineModelBuilder.h.
typedef Base::EvalUnitPropertyBundle OfflineModelBuilder< EvalGraphT >::EvalUnitPropertyBundle |
Reimplemented from OnlineModelBuilder< EvalGraphT >.
Definition at line 57 of file OfflineModelBuilder.h.
typedef Base::Model OfflineModelBuilder< EvalGraphT >::Model |
Reimplemented from OnlineModelBuilder< EvalGraphT >.
Definition at line 59 of file OfflineModelBuilder.h.
typedef MyModelGraph::ModelList OfflineModelBuilder< EvalGraphT >::ModelList |
Reimplemented from OnlineModelBuilder< EvalGraphT >.
Definition at line 62 of file OfflineModelBuilder.h.
typedef ModelList::const_iterator OfflineModelBuilder< EvalGraphT >::ModelListIterator |
Definition at line 63 of file OfflineModelBuilder.h.
typedef Base::ModelPropertyBundle OfflineModelBuilder< EvalGraphT >::ModelPropertyBundle |
Reimplemented from OnlineModelBuilder< EvalGraphT >.
Definition at line 60 of file OfflineModelBuilder.h.
typedef Base::MyModelGraph OfflineModelBuilder< EvalGraphT >::MyModelGraph |
Reimplemented from OnlineModelBuilder< EvalGraphT >.
Definition at line 58 of file OfflineModelBuilder.h.
typedef boost::vector_property_map<OfflineModelBuildingProperties> OfflineModelBuilder< EvalGraphT >::OfflineModelBuildingPropertyMap [protected] |
Definition at line 87 of file OfflineModelBuilder.h.
typedef Base::OptionalModel OfflineModelBuilder< EvalGraphT >::OptionalModel |
Reimplemented from OnlineModelBuilder< EvalGraphT >.
Definition at line 61 of file OfflineModelBuilder.h.
typedef boost::optional<ModelListIterator> OfflineModelBuilder< EvalGraphT >::OptionalModelListIterator |
Reimplemented from OnlineModelBuilder< EvalGraphT >.
Definition at line 64 of file OfflineModelBuilder.h.
typedef OfflineModelBuilder<EvalGraphT> OfflineModelBuilder< EvalGraphT >::Self |
Reimplemented from OnlineModelBuilder< EvalGraphT >.
Definition at line 53 of file OfflineModelBuilder.h.
OfflineModelBuilder< EvalGraphT >::OfflineModelBuilder | ( | ModelBuilderConfig< EvalGraphT > & | cfg | ) | [inline] |
Constructor.
cfg | Configuration. |
Definition at line 100 of file OfflineModelBuilder.h.
References ModelBuilderConfig< EvalGraphT >::eg, ModelBuilder< EvalGraphT >::eg, and OfflineModelBuilder< EvalGraphT >::offmbp.
virtual OfflineModelBuilder< EvalGraphT >::~OfflineModelBuilder | ( | ) | [inline, virtual] |
Destructor.
Definition at line 110 of file OfflineModelBuilder.h.
unsigned OfflineModelBuilder< EvalGraphT >::buildIModels | ( | EvalUnit | u | ) | [virtual] |
Builds the input models at the given.
u | Unit whose input models are to be computed. |
Definition at line 135 of file OfflineModelBuilder.h.
References DBGLOG, CAUAlgorithms::findCAUs(), CAUAlgorithms::initJoinRelevance(), LOG, LOG_VSCOPE, CAUAlgorithms::logAPM(), CAUAlgorithms::logJRPM(), and CAUAlgorithms::markJoinRelevance().
unsigned OfflineModelBuilder< EvalGraphT >::buildIModelsRecursively | ( | EvalUnit | u | ) | [virtual] |
Definition at line 254 of file OfflineModelBuilder.h.
References DBGLOG, LOG, LOG_VSCOPE, MT_IN, and printptr().
Referenced by main().
unsigned OfflineModelBuilder< EvalGraphT >::buildOModels | ( | EvalUnit | u | ) | [virtual] |
Builds the output models at the given.
u | Unit whose output models are to be computed. |
Definition at line 218 of file OfflineModelBuilder.h.
References DBGLOG, CAUAlgorithms::initJoinRelevance(), LOG, and LOG_VSCOPE.
unsigned OfflineModelBuilder< EvalGraphT >::buildOModelsRecursively | ( | EvalUnit | u | ) | [virtual] |
Definition at line 292 of file OfflineModelBuilder.h.
References DBGLOG, LOG, LOG_VSCOPE, MT_OUT, and printptr().
EvalGraphT& OfflineModelBuilder< EvalGraphT >::getEvalGraph | ( | ) | [inline] |
Returns the internal evaluation graph.
Reimplemented from ModelBuilder< EvalGraphT >.
Definition at line 112 of file OfflineModelBuilder.h.
References ModelBuilder< EvalGraphT >::getEvalGraph().
Referenced by main().
MyModelGraph& OfflineModelBuilder< EvalGraphT >::getModelGraph | ( | ) | [inline] |
Returns the internal model graph.
Reimplemented from ModelBuilder< EvalGraphT >.
Definition at line 113 of file OfflineModelBuilder.h.
References ModelBuilder< EvalGraphT >::getModelGraph().
Referenced by main().
OfflineModelBuilder< EvalGraphT >::OptionalModel OfflineModelBuilder< EvalGraphT >::getNextIModel | ( | EvalUnit | u | ) | [protected, virtual] |
Get next input model (projected if projection is configured) at e given unit.
u | The unit whose next input model shall be returned. |
u
. Reimplemented from OnlineModelBuilder< EvalGraphT >.
Definition at line 323 of file OfflineModelBuilder.h.
References DBGLOG, LOG, LOG_VSCOPE, and MT_IN.
void OfflineModelBuilder< EvalGraphT >::printEvalGraphModelGraph | ( | std::ostream & | o | ) | [inline, virtual] |
Prints both the evaluation and the model graph for debugging purposes.
o | The stream to print to. |
Reimplemented from OnlineModelBuilder< EvalGraphT >.
Definition at line 114 of file OfflineModelBuilder.h.
References OnlineModelBuilder< EvalGraphT >::printEvalGraphModelGraph().
Referenced by main().
void OfflineModelBuilder< EvalGraphT >::printModelBuildingPropertyMap | ( | std::ostream & | o | ) | [inline, virtual] |
Prints the model building properties for debugging purposes.
o | The stream to print to. |
Reimplemented from OnlineModelBuilder< EvalGraphT >.
Definition at line 115 of file OfflineModelBuilder.h.
References OnlineModelBuilder< EvalGraphT >::printModelBuildingPropertyMap().
boost::optional<CAUAlgorithms::JoinRelevancePropertyMap> OfflineModelBuilder< EvalGraphT >::currentjrp [protected] |
For each call we need this storage, this is not threadsafe! (but the rest of model building is unlikely to be threadsafe as well).
Definition at line 94 of file OfflineModelBuilder.h.
OfflineModelBuildingPropertyMap OfflineModelBuilder< EvalGraphT >::offmbp [protected] |
Properties of models.
Definition at line 92 of file OfflineModelBuilder.h.
Referenced by OfflineModelBuilder< EvalGraphT >::OfflineModelBuilder().