diff options
author | Chris Dyer <cdyer@cs.cmu.edu> | 2011-10-31 14:03:22 -0400 |
---|---|---|
committer | Chris Dyer <cdyer@cs.cmu.edu> | 2011-10-31 14:03:22 -0400 |
commit | 6de8f58cd13813bf33af4903bf386439683c0fd6 (patch) | |
tree | c61ce14a652f04ca964fe7ac5ff3c4fd43d23a29 /word-aligner/ortho-norm | |
parent | ac85e18b071d961f52e1fa9aafd30b36c676dc4b (diff) |
lbfgs + time-series minibatch optimization
Diffstat (limited to 'word-aligner/ortho-norm')
-rwxr-xr-x | word-aligner/ortho-norm/mg.pl | 13 | ||||
-rwxr-xr-x | word-aligner/ortho-norm/rw.pl | 13 |
2 files changed, 26 insertions, 0 deletions
diff --git a/word-aligner/ortho-norm/mg.pl b/word-aligner/ortho-norm/mg.pl new file mode 100755 index 00000000..4cb0e8e7 --- /dev/null +++ b/word-aligner/ortho-norm/mg.pl @@ -0,0 +1,13 @@ +#!/usr/bin/perl -w +use strict; +use utf8; + +binmode(STDIN, ":utf8"); +binmode(STDOUT, ":utf8"); + +while(<STDIN>) { + $_ = lc $_; + s/([a-z])'( |$)/$1$2/g; + print; +} + diff --git a/word-aligner/ortho-norm/rw.pl b/word-aligner/ortho-norm/rw.pl new file mode 100755 index 00000000..4cb0e8e7 --- /dev/null +++ b/word-aligner/ortho-norm/rw.pl @@ -0,0 +1,13 @@ +#!/usr/bin/perl -w +use strict; +use utf8; + +binmode(STDIN, ":utf8"); +binmode(STDOUT, ":utf8"); + +while(<STDIN>) { + $_ = lc $_; + s/([a-z])'( |$)/$1$2/g; + print; +} + |