28 #ifndef GUM_LEARNING_STRUCTURAL_CONSTRAINT_FORBIDDEN_ARCS_H 29 #define GUM_LEARNING_STRUCTURAL_CONSTRAINT_FORBIDDEN_ARCS_H 31 #include <agrum/agrum.h> 32 #include <agrum/tools/graphs/diGraph.h> 33 #include <agrum/BN/learning/constraints/structuralConstraint.h> 34 #include <agrum/BN/learning/structureUtils/graphChange.h> 88 void setArcs(
const ArcSet& set);
91 void addArc(
const Arc& arc);
182 #ifndef DOXYGEN_SHOULD_SKIP_THIS 186 # define GUM_CONSTRAINT_CLASS_NAME StructuralConstraintForbiddenArcs 187 # include <agrum/BN/learning/constraints/structuralConstraintPatternHeader.h> 188 # undef GUM_CONSTRAINT_CLASS_NAME 201 #ifndef GUM_NO_INLINE 202 # include <agrum/BN/learning/constraints/structuralConstraintForbiddenArcs_inl.h> StructuralConstraintForbiddenArcs(const DiGraph &graph)
constructor starting with a given graph
the structural constraint for forbidding the creation of some arcs during structure learning ...
virtual ~StructuralConstraintForbiddenArcs()
destructor
void addArc(const Arc &arc)
assign a new forbidden arc
INLINE void emplace(Args &&... args)
StructuralConstraintForbiddenArcs(StructuralConstraintForbiddenArcs &&from)
move constructor
StructuralConstraintForbiddenArcs & operator=(const StructuralConstraintForbiddenArcs &from)
copy operator
void setArcs(const ArcSet &set)
assign a set of forbidden arcs
bool checkModificationAlone(const ArcReversal &change) const
checks whether the constraints enable to reverse an arc
void setGraphAlone(const DiGraph &graph)
sets a new graph from which we will perform checkings
void eraseArc(const Arc &arc)
remove a forbidden arc
const ArcSet & arcs() const
returns the set of mandatory arcs
bool isAlwaysInvalidAlone(const GraphChange &change) const
indicates whether a change will always violate the constraint
StructuralConstraintForbiddenArcs & operator=(StructuralConstraintForbiddenArcs &&from)
move operator
bool checkArcAdditionAlone(NodeId x, NodeId y) const
checks whether the constraints enable to add arc (x,y)
StructuralConstraintForbiddenArcs(const StructuralConstraintForbiddenArcs &from)
copy constructor
ArcSet _ForbiddenArcs_forbidden_arcs_
the ForbiddenArcs on which we perform checks
bool checkArcReversalAlone(NodeId x, NodeId y) const
checks whether the constraints enable to reverse arc (x,y)
StructuralConstraintForbiddenArcs()
default constructor
Database(const std::string &filename, const BayesNet< GUM_SCALAR > &bn, const std::vector< std::string > &missing_symbols)
void modifyGraphAlone(const GraphChange &change)
notify the constraint of a modification of the graph
bool checkArcDeletionAlone(NodeId x, NodeId y) const
checks whether the constraints enable to remove arc (x,y)