Download & Install

Download

You can download Ncode from here. The tarball contains the source code of our decoder as well as multiple additional scripts that are used for training (build models), tuninig (optimization of model weights) and testing (translate unseen data).


Install

Unpack the tarball bincoder-v1.0.0.tgz somewhere in your file system (in my case somewhere=/home/jmcrego/licensed-soft) using:
$> tar xvzf bincoder-v1.0.0.tgz 

The next file structure is created:
bincoder-v1.0.0
|-- HISTORY
|-- INSTALL
|-- LICENSE
|-- Makefile
`-- src
    |-- Argument.cpp
    |-- Argument.h
    |-- Auxiliar.h
    |-- BeamSrch.cpp
    |-- BeamSrch.h
    |-- Evaluate
    |   |-- mteval-v13.pl
    |   |-- mteval-v13a.pl
    |   `-- multi-bleu.perl
    |-- LangMods.cpp
    |-- LangMods.h
    |-- TestFile.cpp
    |-- TestFile.h
    |-- alig2lex.perl
    |-- alig2unf
    |-- alig2unf.cpp
    |-- bincoder.cpp
    |-- bincoder.perl
    |-- binfiltr.cpp
    |-- evaluate.perl
    |-- feat_lex.cpp
    |-- gph2nbst.cpp
    |-- lexreord.perl
    |-- mert-run.perl
    |-- mert-tst.perl
    |-- mert-say.perl
    |-- posrules.cpp
    |-- prunetpl.perl
    |-- prunevoc.perl
    |-- srcNULLs.cpp
    |-- training.perl
    |-- unf+null.perl
    |-- unf2fact.cpp
    `-- unf2utrn.perl

Before compiling Ncode, some environment variables must be used (BINCODER, OPENFST and KENLM). They must point to the corresponding software toolkits. In my case (using bash) I just added the next variables into my .bashrc file:
$> export BINCODER=/home/jmcrego/licensed-soft/bincoder-v1.0.0
$> export OPENFST=/home/jmcrego/licensed-soft/openfst-1.2.7
$> export KENLM=/home/jmcrego/licensed-soft/kenlm

Make sure that OpenFST dynamic libraries are available through the $LD_LIBRARY_PATH var:
$> export LD_LIBRARY_PATH=/people/licensed-soft/openfst-1.2.7/lib

Two other environment variables are needed when using Ncode (SRILM and MERT). In my case I use:
$> export SRILM=/home/jmcrego/licensed-soft/srilm/bin/i686
$> export MERT=/home/jmcrego/licensed-soft/moses/mert

Finally, you can just use the classical:
$> make

Binaries are created in $BINCODER/bin. We recommend to update your PATH environment variable to allow runing Ncode from anywhere in your file system. In my case I use:
$> PATH=$PATH:/home/jmcrego/licensed-soft/bincoder-v1.0.0/bin

You can freely download the previous software toolkits from their web sites: