Download tools/mosesdecoder/moses/Syntax/F2S/Manager.h from Quagmire1/wiki-cased: direct link, hf CLI and curl.
- Browser
- Download file 1.63 kB
-
https://huggingface.co/Quagmire1/wiki-cased/resolve/main/tools/mosesdecoder/moses/Syntax/F2S/Manager.h
- Command line
-
hf download hf://Quagmire1/wiki-cased/tools/mosesdecoder/moses/Syntax/F2S/Manager.h
-
curl -L -o Manager.h https://huggingface.co/Quagmire1/wiki-cased/resolve/main/tools/mosesdecoder/moses/Syntax/F2S/Manager.h
1.63 kB
| namespace Moses | |
| { | |
| namespace Syntax | |
| { | |
| struct SHyperedge; | |
| namespace F2S | |
| { | |
| template<typename RuleMatcher> | |
| class Manager : public Syntax::Manager | |
| { | |
| public: | |
| Manager(ttasksptr const& ttask); | |
| void Decode(); | |
| // Get the SHyperedge for the 1-best derivation. | |
| const SHyperedge *GetBestSHyperedge() const; | |
| typedef std::vector<boost::shared_ptr<KBestExtractor::Derivation> > kBestList_t; | |
| void ExtractKBest(std::size_t k, kBestList_t& kBestList, | |
| bool onlyDistinct=false) const; | |
| void OutputDetailedTranslationReport(OutputCollector *collector) const; | |
| private: | |
| const Forest::Vertex &FindRootNode(const Forest &); | |
| void InitializeRuleMatchers(); | |
| void InitializeStacks(); | |
| bool IsUnknownSourceWord(const Word &) const; | |
| void RecombineAndSort(const std::vector<SHyperedge*> &, SVertexStack &); | |
| boost::shared_ptr<const Forest> m_forest; | |
| const Forest::Vertex *m_rootVertex; | |
| std::size_t m_sentenceLength; // Includes <s> and </s> | |
| PVertexToStackMap m_stackMap; | |
| boost::shared_ptr<HyperTree> m_glueRuleTrie; | |
| std::vector<boost::shared_ptr<RuleMatcher> > m_mainRuleMatchers; | |
| boost::shared_ptr<RuleMatcher> m_glueRuleMatcher; | |
| }; | |
| } // F2S | |
| } // Syntax | |
| } // Moses | |
| // Implementation | |