00001 #pragma once
00002
00003 #include <istream>
00004 #include <vector>
00005
00006 #include <boost/unordered_set.hpp>
00007
00008 #include "moses/TypeDef.h"
00009 #include "moses/Syntax/RuleTableFF.h"
00010
00011 #include "HyperPath.h"
00012 #include "HyperTree.h"
00013 #include "HyperTreeCreator.h"
00014
00015 namespace Moses
00016 {
00017 class AllOptions;
00018 namespace Syntax
00019 {
00020 namespace F2S
00021 {
00022
00023 class HyperTreeLoader : public HyperTreeCreator
00024 {
00025 public:
00026 bool Load(AllOptions const& opts,
00027 const std::vector<FactorType> &input,
00028 const std::vector<FactorType> &output,
00029 const std::string &inFile,
00030 const RuleTableFF &,
00031 HyperTree &,
00032 boost::unordered_set<std::size_t> &);
00033
00034 private:
00035 void ExtractSourceTerminalSetFromHyperPath(
00036 const HyperPath &, boost::unordered_set<std::size_t> &);
00037 };
00038
00039 }
00040 }
00041 }