Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/marian-nmt/marian.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHieu Hoang <hieuhoang@gmail.com>2017-03-13 00:04:21 +0300
committerHieu Hoang <hieuhoang@gmail.com>2017-03-13 00:04:21 +0300
commitc3591e613c52c798091acf50317ac8fdffa6716c (patch)
tree8d5bbc587d4b0e5084aaaa72d78da058f9d89256 /scripts
parent6703aa2a3c835fc7681f8fb848eee006afff374e (diff)
parentd33c4e0c5cab0f97c2e9061ccb0631d9381a5383 (diff)
mergedev
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/amun.py15
1 files changed, 15 insertions, 0 deletions
diff --git a/scripts/amun.py b/scripts/amun.py
new file mode 100755
index 00000000..98d94c3b
--- /dev/null
+++ b/scripts/amun.py
@@ -0,0 +1,15 @@
+#!/usr/bin/env python
+# script by Ulrich Germann
+# This script is meant to test the python interface of amun by emulating the amun executable.
+import sys, os
+
+if 'AMUN_PYLIB_DIR' in os.environ:
+ sys.path.append(os.environ['AMUN_PYLIB_DIR'])
+ pass
+
+import libamunmt
+if __name__ == "__main__":
+ libamunmt.init(" ".join(sys.argv[1:]))
+ print libamunmt.translate(sys.stdin.readlines())
+ libamunmt.shutdown()
+