48#ifndef GUM_MRF_GUM_READER_H
49#define GUM_MRF_GUM_READER_H
69 template < GUM_Numeric GUM_SCALAR >
80 std::string_view filename,
103 template <
typename JsonType >
106 MarkovRandomField< GUM_SCALAR >*
_mrf_;
113#ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
Definition of abstract classes for file input manipulation of Markov random fields.
ErrorsContainer()
Class Constructor.
Reads a MarkovRandomField from a GUM (json) file.
Size proceedFromString(std::string_view content)
Parse a jgum JSON string directly (no file I/O).
GumMRFReader(MarkovRandomField< GUM_SCALAR > *mrf, std::string_view filename, bool binary=false)
Constructor.
Size _proceedFromJson_(const JsonType &content)
Size proceed() override
Parses the file and populates the MarkovRandomField.
MarkovRandomField< GUM_SCALAR > * _mrf_
void showElegantErrorsAndWarnings(std::ostream &stream=std::cerr) const
void showErrorCounts(std::ostream &stream=std::cerr) const
GumMRFReader(MarkovRandomField< GUM_SCALAR > *mrf)
Constructor for string-based parsing only (no file). Use exclusively with proceedFromString(); callin...
MRFReader(MarkovRandomField< GUM_SCALAR > *MN, std::string_view filename)
Constructor A reader is defined for reading a defined file.
Errors container (at least) for parser.
std::size_t Size
In aGrUM, hashed values are unsigned long int.
gum is the global namespace for all aGrUM entities