I am writing this article for remarking.
Ubuntu version: 12.04
Introduction
Lingua::Align is a collection of command-line tools for automatic tree and word alignment of parallel corpora. The main purpose is to provide an experimental toolbox for experiments with various feature sets and alignment strategies. Alignment is based on local classification and alignment inference. The local classifier is typically trained on available aligned training data. We use a log-linear model for discriminative binary classification using the maximum entropy learning package megam (Hal Daume III).
Installation
When install this tool, the requirement is a recent version of Perl, XML::Parser, Algorithm::Munkres and megaminstalled on your system.
- Install XML::Parser
sudo apt-get install libxml-parser-perl
- Install Algorithm::Munkres
sudo apt-get install libalgorithm-munkres-perl
- Install megem (http://www.umiacs.umd.edu/~hal/megam/index.html)
The software here is an implementation ofmaximum likelihood and maximum a posterior optimization of theparameters of these models. The algorithms used are much moreefficient than the iterative scaling techniques used in almost everyother maxent package out there.
The sources are in util.ml, data.ml, cg.ml, bfgs.ml and data.ml. There is a Makefile to you can build it on any system that has ocaml. (http://caml.inria.fr)
So we can just install the ocaml simply by execute
sudo apt-get install ocaml make
- Install Lingua::Align (https://bitbucket.org/tiedemann/lingua-align/wiki/Home)
Download the package from the given link above and unzip it.
You can either install the perl modules and binaries as usual:
perl Makefile.PL make make install
Trouble shot
When install the megem, it will return the following error:
/user/bin/ld: cannot find -lstr
This is a bug in the OCaml bug tracker:Bug 5247
The fix method is:locate libcamlstr cd /usr/lib/ocaml sudo ln -s libcamlstr.a libstr.a
Experiment
Run your own experiment by following Tutorial