Here is how you do it:
Create and move to your install folder, then:
Create and move to your install folder, then:
curl http://giza-pp.googlecode.com/files/giza-pp-v1.0.7.tar.gz -o giza-pp-v1.0.7.tar.gz
tar -xzvf giza-pp-v1.0.7.tar.gz
cd giza-pp
perl -pi -w -e 's/<tr1\//</g;' GIZA++-v2/* mkcls-v2/*
perl -pi -w -e 's/using namespace std::tr1;//g;' GIZA++-v2/* mkcls-v2/*
perl -pi -w -e 's/std::tr1:://g;' GIZA++-v2/* mkcls-v2/*
sed '36d' mkcls-v2/mystl.h > mkcls-v2/mystl.h.tmp
sed '50d' mkcls-v2/mystl.h.tmp > mkcls-v2/mystl.h
rm mkcls-v2/mystl.h.tmp
make
(The first 3 lines download and decompress the GIZA++ archive. The last 5 lines remove all the references to tr1.)
Enjoy!
Thank you so much! Worked perfectly!
ReplyDeleteWaouh! My first reader! I'm glad you like it :)
ReplyDeleteAnother reader here, thanks!
ReplyDeleteThanks, that was really helpful!
ReplyDeleteThanks a lot. It was very helpful. :)
ReplyDeleteThanks, this also worked for me. I'm curious -- is there a downside to removing the tr1 references? Will this break other parts of the giza++ code? Also, I still get two warnings after doing "make" which are "illegal character encoding in string literal [-Winvalid-source-encoding]" but hopefully this is not a problem?
ReplyDeleteSince Google Code is no longer online, the URL in the curl command should be replaced with https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/moses-suite/giza-pp-v1.0.7.tar.gz
ReplyDeleteThank you. This post is helpful to me
ReplyDeleteThank you, after I deeply troubled by error about one hour, I find your blog.
ReplyDeleteIt's brilliant!
Thank you!!
ReplyDeleteVery useful, many thanks|
ReplyDeleteThanks a lot for this. I only had to the first command, since the code is hosted on Github now. I used this instead git clone https://github.com/moses-smt/giza-pp.git
ReplyDeleteYou can still follow her initial instructions, but change the curl link to:
ReplyDeletehttps://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/moses-suite/giza-pp-v1.0.7.tar.gz
awesome thanks!
ReplyDeleteDo you know how did you run on MAC. It is installed and now I don't know how to run to get the psuedo code.
DeleteHow to run then?
ReplyDeletehow to install on pc
ReplyDelete