Class EncoderClassifierBase¶
Defined in File encoder_classifier.h
Inheritance Relationships¶
Base Type¶
public IModel
Derived Type¶
public marian::EncoderClassifier
(Class EncoderClassifier)
Class Documentation¶
-
class
EncoderClassifierBase
: public IModel¶ Combines sequence encoders with generic classifiers Can be used to train sequence classifiers like language detection, BERT-next-sentence-prediction etc.
Already has support for multi-objective training.
@TODO: this should probably be unified somehow with EncoderDecoder which could allow for decoder/classifier multi-objective training.
Subclassed by marian::EncoderClassifier
Public Functions
-
virtual
~EncoderClassifierBase
()¶
-
virtual void
load
(Ptr<ExpressionGraph> graph, const std::string &name, bool markedReloaded = true) = 0¶
-
virtual void
mmap
(Ptr<ExpressionGraph> graph, const void *ptr, bool markedReloaded = true) = 0¶
-
virtual void
save
(Ptr<ExpressionGraph> graph, const std::string &name, bool saveTranslatorConfig = false) = 0¶
-
virtual void
clear
(Ptr<ExpressionGraph> graph) = 0¶
-
virtual std::vector<Ptr<ClassifierState>>
apply
(Ptr<ExpressionGraph>, Ptr<data::CorpusBatch>, bool) = 0¶
-
virtual Logits
build
(Ptr<ExpressionGraph> graph, Ptr<data::Batch> batch, bool clearGraph = true) = 0¶
-
virtual Logits
build
(Ptr<ExpressionGraph> graph, Ptr<data::CorpusBatch> batch, bool clearGraph = true) = 0¶
-
virtual