From ec7edcc7e398bdb040d810094b8416ad9f279d98 Mon Sep 17 00:00:00 2001 From: Chris Dyer Date: Mon, 7 Dec 2009 01:50:49 -0500 Subject: minor changes to the way the phonotactic prob is calculated --- src/sentence_metadata.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/sentence_metadata.h') diff --git a/src/sentence_metadata.h b/src/sentence_metadata.h index 0178f1f5..ef9eb388 100644 --- a/src/sentence_metadata.h +++ b/src/sentence_metadata.h @@ -27,11 +27,16 @@ struct SentenceMetadata { int GetSourceLength() const { return src_len_; } int GetTargetLength() const { return trg_len_; } int GetSentenceID() const { return sent_id_; } + // this will be empty if the translator accepts non FS input! + const Lattice& GetSourceLattice() const { return src_lattice_; } private: const int sent_id_; + // the following should be set, if possible, by the Translator int src_len_; - + public: + Lattice src_lattice_; // this will only be set if inputs are finite state! + private: // you need to be very careful when depending on these values // they will only be set during training / alignment contexts const bool has_reference_; -- cgit v1.2.3