KnowledgeDatabase.h
Go to the documentation of this file.
1 /*
2  * KnowledgeDatabase.h
3  *
4  * Created on: September, 2012
5  * Author: sdries
6  */
7 
8 #ifndef WM_KNOWLEDGEDATABASE_H_
9 #define WM_KNOWLEDGEDATABASE_H_
10 
11 #include <problib/pdfs/PMF.h>
12 #include "wire/core/ClassModel.h"
13 
14 #include <map>
15 
16 namespace mhf {
17 
18 class Evidence;
19 class SemanticObject;
20 
22 
23 public:
24 
26 
27  virtual ~KnowledgeDatabase();
28 
29  void addClassModel(const std::string& class_name, ClassModel* model);
30 
31  const PropertySet& getNewPDFs(const std::string& class_name) const;
32 
33  const PropertySet& getClutterPDFs(const std::string& class_name) const;
34 
35  const IStateEstimator* getEstimator(const std::string& class_name, const Attribute& attribute) const;
36 
37  const pbl::PMF& getClassDistribution() const;
38 
39  const std::map<std::string, ClassModel*>& getClassModels() const;
40 
41  const ClassModel* getClassModel(const std::string& class_name) const;
42 
43  void setPriorNew(double prior_new);
44 
45  void setPriorExisting(double prior_existing);
46 
47  void setPriorClutter(double prior_clutter);
48 
49  double getPriorNew() const;
50 
51  double getPriorExisting() const;
52 
53  double getPriorClutter() const;
54 
55  double getProbabilityNew(const Evidence& z);
56 
57  double getProbabilityClutter(const Evidence& z);
58 
59  double getProbabilityExisting(const Evidence& z, const SemanticObject& obj);
60 
61  std::vector<Property> inferProperties(const PropertySet& prop_set, std::vector<Attribute>) const;
62 
63 protected:
64 
66 
68 
69  double prior_new_;
70 
72 
74 
76 
77  std::map<std::string, ClassModel*> class_models_;
78 
79 };
80 
81 }
82 
83 #endif /* PROPERTYDATABASE_H_ */
const ClassModel * getClassModel(const std::string &class_name) const
void setPriorExisting(double prior_existing)
void setPriorClutter(double prior_clutter)
const std::map< std::string, ClassModel * > & getClassModels() const
void setPriorNew(double prior_new)
void addClassModel(const std::string &class_name, ClassModel *model)
double getPriorClutter() const
const PropertySet & getNewPDFs(const std::string &class_name) const
Base class for all state estimators used by the world model.
static KnowledgeDatabase & getInstance()
const IStateEstimator * getEstimator(const std::string &class_name, const Attribute &attribute) const
The class Evidence represents a set of properties (PropertySet) that all originate from one physical ...
Definition: Evidence.h:61
double getProbabilityExisting(const Evidence &z, const SemanticObject &obj)
int Attribute
Definition: datatypes.h:49
static KnowledgeDatabase * instance_
Contains knowledge about a specific object class on where to expect new objects of that class (new) a...
Definition: ClassModel.h:57
double getProbabilityClutter(const Evidence &z)
std::vector< Property > inferProperties(const PropertySet &prop_set, std::vector< Attribute >) const
TFSIMD_FORCE_INLINE const tfScalar & z() const
const PropertySet & getClutterPDFs(const std::string &class_name) const
std::map< std::string, ClassModel * > class_models_
double getPriorExisting() const
double getProbabilityNew(const Evidence &z)
const pbl::PMF & getClassDistribution() const
Definition: ClassModel.h:44


wire_core
Author(s): Sjoerd van den Dries, Jos Elfring
autogenerated on Fri Apr 16 2021 02:32:27