diff options
author | Chris Dyer <cdyer@cs.cmu.edu> | 2012-02-29 01:12:40 -0500 |
---|---|---|
committer | Chris Dyer <cdyer@cs.cmu.edu> | 2012-02-29 01:12:40 -0500 |
commit | 71df4aeddd3d0de93e96da0e77c5aca119fec37f (patch) | |
tree | 958e4148cd4f22c2253f42278127a6bf41d29959 /utils/corpus_tools.h | |
parent | 00d0b3b462bd9fd230b25b3ab6021c197980bdff (diff) |
cleanup, mpi-ify lblmodel
Diffstat (limited to 'utils/corpus_tools.h')
-rw-r--r-- | utils/corpus_tools.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/utils/corpus_tools.h b/utils/corpus_tools.h new file mode 100644 index 00000000..97bdaa94 --- /dev/null +++ b/utils/corpus_tools.h @@ -0,0 +1,19 @@ +#ifndef _CORPUS_TOOLS_H_ +#define _CORPUS_TOOLS_H_ + +#include <string> +#include <set> +#include <vector> +#include "wordid.h" + +struct CorpusTools { + static void ReadFromFile(const std::string& filename, + std::vector<std::vector<WordID> >* src, + std::set<WordID>* src_vocab = NULL, + std::vector<std::vector<WordID> >* trg = NULL, + std::set<WordID>* trg_vocab = NULL, + int rank = 0, + int size = 1); +}; + +#endif |