diff options
author | redpony <redpony@ec762483-ff6d-05da-a07a-a48fb63a330f> | 2010-11-10 02:02:04 +0000 |
---|---|---|
committer | redpony <redpony@ec762483-ff6d-05da-a07a-a48fb63a330f> | 2010-11-10 02:02:04 +0000 |
commit | 47a656c0b6fdba8f91f2c5808234cbb1de682652 (patch) | |
tree | 638e1e9226ef6dc403b752b98d9fadb56f74c69e /klm/lm/build_binary.cc | |
parent | 0c83a47353733c85814871a9a656cafdc70e6800 (diff) |
new version of klm
git-svn-id: https://ws10smt.googlecode.com/svn/trunk@706 ec762483-ff6d-05da-a07a-a48fb63a330f
Diffstat (limited to 'klm/lm/build_binary.cc')
-rw-r--r-- | klm/lm/build_binary.cc | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/klm/lm/build_binary.cc b/klm/lm/build_binary.cc new file mode 100644 index 00000000..4db631a2 --- /dev/null +++ b/klm/lm/build_binary.cc @@ -0,0 +1,13 @@ +#include "lm/model.hh" + +#include <iostream> + +int main(int argc, char *argv[]) { + if (argc != 3) { + std::cerr << "Usage: " << argv[0] << " input.arpa output.mmap" << std::endl; + return 1; + } + lm::ngram::Config config; + config.write_mmap = argv[2]; + lm::ngram::Model(argv[1], config); +} |