![]() |
aGrUM 2.3.2
a C++ library for (probabilistic) graphical models
|
<agrum/BN/io/cnf/FactorisedValuesCNFWriter.h> More...
#include <FactorisedValuesCNFWriter.h>
Public Member Functions | |
| void | write (std::ostream &output, const IBayesNet< GUM_SCALAR > &bn) |
| Writes a Bayesian network in the output stream. | |
| void | write (const std::string &filePath, const IBayesNet< GUM_SCALAR > &bn) |
| Writes a Bayesian network in the file referenced by filePath. | |
| GUM_NODISCARD bool | isModificationAllowed () const |
| void | setAllowModification (bool am) |
Constructor & destructor | |
| FactorisedValuesCNFWriter () | |
| Default constructor. | |
| ~FactorisedValuesCNFWriter () | |
| Destructor. | |
Accessors/Modifiers | |
| void | combineAdd (const ApproximationPolicy< GUM_SCALAR > *ap) |
| Combine using addition with the given gum::ApproximationPolicy. | |
| void | combineSub (const ApproximationPolicy< GUM_SCALAR > *ap) |
| Combine using substraction with the given gum::ApproximationPolicy. | |
| void | combineMult (const ApproximationPolicy< GUM_SCALAR > *ap) |
| Combine using multiplication with the given gum::ApproximationPolicy. | |
| void | combineDiv (const ApproximationPolicy< GUM_SCALAR > *ap) |
| Combine using division with the given gum::ApproximationPolicy. | |
| void | combineMax (const ApproximationPolicy< GUM_SCALAR > *ap) |
| Combine using max with the given gum::ApproximationPolicy. | |
| void | combineMin (const ApproximationPolicy< GUM_SCALAR > *ap) |
| Combine using min with the given gum::ApproximationPolicy. | |
Protected Member Functions | |
| void | _doWrite (std::ostream &output, const IBayesNet< GUM_SCALAR > &bn) final |
| Writes a Bayesian network in the output stream using the BN format. | |
| void | _doWrite (const std::string &filePath, const IBayesNet< GUM_SCALAR > &bn) final |
| Writes a Bayesian network in the referenced file using the BN format. | |
| GUM_SCALAR | fromExact (const GUM_SCALAR &value) const override |
| Convert value to his approximation. | |
| virtual void | _syntacticalCheck (const IBayesNet< GUM_SCALAR > &bn) |
| Check whether the BN is syntactically correct for BIF format. | |
| void | _validCharInNamesCheck (const IBayesNet< GUM_SCALAR > &bn) |
| } | |
| std::string | _onlyValidCharsInName (const std::string &name) |
| } | |
| std::string | _buildNameWithOnlyValidChars (const std::string &name) |
| } | |
| bool | _allowModification_ |
| } | |
<agrum/BN/io/cnf/FactorisedValuesCNFWriter.h>
Writes a IBayesNet in the BN format.
This class servers to write the content of a Bayesian network in the BN format. See TODO for information on this format.
Definition at line 79 of file FactorisedValuesCNFWriter.h.
| gum::FactorisedValuesCNFWriter< GUM_SCALAR, IApproximationPolicy >::FactorisedValuesCNFWriter | ( | ) |
Default constructor.
| gum::FactorisedValuesCNFWriter< GUM_SCALAR, IApproximationPolicy >::~FactorisedValuesCNFWriter | ( | ) |
Destructor.
|
protectedinherited |
}
|
finalprotectedvirtual |
Writes a Bayesian network in the referenced file using the BN format.
If the files doesn't exists, it is created.
| filePath | The path to the file used to write the Bayesian network. |
| bn | The Bayesian network writed in the file. |
| IOError | Raised if and I/O error occurs. |
Implements gum::BNWriter< GUM_SCALAR >.
|
finalprotectedvirtual |
Writes a Bayesian network in the output stream using the BN format.
| output | The output stream. |
| bn | The Bayesian network writen in output. |
| IOError | Raised if and I/O error occurs. |
Implements gum::CNFWriter< GUM_SCALAR, ExactPolicy >.
|
protectedinherited |
}
|
protectedvirtualinherited |
Check whether the BN is syntactically correct for BIF format.
| FatalError | if found. |
|
protectedinherited |
}
|
inherited |
Combine using addition with the given gum::ApproximationPolicy.
| ap | The policy to combine with. |
Definition at line 97 of file exactPolicy_tpl.h.
|
inherited |
Combine using division with the given gum::ApproximationPolicy.
| ap | The policy to combine with. |
Definition at line 117 of file exactPolicy_tpl.h.
|
inherited |
Combine using max with the given gum::ApproximationPolicy.
| ap | The policy to combine with. |
Definition at line 123 of file exactPolicy_tpl.h.
|
inherited |
Combine using min with the given gum::ApproximationPolicy.
| ap | The policy to combine with. |
Definition at line 129 of file exactPolicy_tpl.h.
|
inherited |
Combine using multiplication with the given gum::ApproximationPolicy.
| ap | The policy to combine with. |
Definition at line 111 of file exactPolicy_tpl.h.
|
inherited |
Combine using substraction with the given gum::ApproximationPolicy.
| ap | The policy to combine with. |
Definition at line 104 of file exactPolicy_tpl.h.
|
inlineoverrideprotectedvirtualinherited |
Convert value to his approximation.
This method, at least in release mode, should not verify the limits
| value | The converted value. |
Implements gum::ApproximationPolicy< GUM_SCALAR >.
Definition at line 129 of file CNFWriter.h.
|
inherited |
|
inherited |
|
inherited |
Writes a Bayesian network in the file referenced by filePath.
| filePath | The path to the file used to write the Bayesian network. |
| bn | The Bayesian network writen in the file. |
| IOError | Raised if an I/O error occurs. |
|
inherited |
Writes a Bayesian network in the output stream.
| output | The output stream. |
| bn | The Bayesian network written in output. |
| IOError | Raised if an I/O error occurs. |
| SyntaxError | Raised if syntactical errors in the BN |
|
privateinherited |
}
Definition at line 163 of file BNWriter.h.