summaryrefslogtreecommitdiff
path: root/realtime/rt/aligner.py
diff options
context:
space:
mode:
authorMichael Denkowski <mdenkows@cs.cmu.edu>2013-09-03 12:13:03 -0700
committerMichael Denkowski <mdenkows@cs.cmu.edu>2013-09-03 12:13:03 -0700
commitdef48bde959fa932cbe87228dc84afc8e635b49b (patch)
treec4e028f3934ac0a581bc0c21e41204a80e385ddb /realtime/rt/aligner.py
parente6f15583081547a4adc2fca7f2ed96cb515a48f5 (diff)
MIRA updates in realtime.py
Diffstat (limited to 'realtime/rt/aligner.py')
-rw-r--r--realtime/rt/aligner.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/realtime/rt/aligner.py b/realtime/rt/aligner.py
index d94dbda0..4a0ace48 100644
--- a/realtime/rt/aligner.py
+++ b/realtime/rt/aligner.py
@@ -23,7 +23,10 @@ class ForceAligner:
self.rev_align = util.popen_io(rev_cmd)
self.tools = util.popen_io(tools_cmd)
- def align(self, line):
+ def align(self, source, target):
+ return self.align_formatted('{} ||| {}'.format(source, target))
+
+ def align_formatted(self, line):
self.fwd_align.stdin.write('{}\n'.format(line))
self.rev_align.stdin.write('{}\n'.format(line))
# f words ||| e words ||| links ||| score