diff options
author | Hieu Hoang <fishandfrolick@gmail.com> | 2012-05-31 20:24:06 +0400 |
---|---|---|
committer | Hieu Hoang <fishandfrolick@gmail.com> | 2012-05-31 20:24:06 +0400 |
commit | 4eef94b1217a82eb979242dd3e06d8a4b6255e6e (patch) | |
tree | bab044ee77c9bf699954ea789078f4c885d66723 /phrase-extract/hierarchical.h | |
parent | c3d4615fc012a5ad5b33a2b587df31064e0ec82b (diff) |
move c++ code out of /script/ to /
Diffstat (limited to 'phrase-extract/hierarchical.h')
-rw-r--r-- | phrase-extract/hierarchical.h | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/phrase-extract/hierarchical.h b/phrase-extract/hierarchical.h new file mode 100644 index 000000000..61c899013 --- /dev/null +++ b/phrase-extract/hierarchical.h @@ -0,0 +1,33 @@ +/* + * hierarchical.h + * + * Created on: Jan 27, 2010 + * Author: Nadi Tomeh - LIMSI/CNRS + * MT Marathon 2010, Dublin + */ + +#ifndef HIERARCHICAL_H_ +#define HIERARCHICAL_H_ + +#include <utility> +#include <map> +#include <set> +#include <vector> + +// HPhraseVertex represents a point in the alignment matrix +typedef std::pair <int, int> HPhraseVertex; + +// Phrase represents a bi-phrase; each bi-phrase is defined by two points in the alignment matrix: +// bottom-left and top-right +typedef std::pair<HPhraseVertex, HPhraseVertex> HPhrase; + +// HPhraseVector is a std::vector of phrases +// the bool value indicates if the associated phrase is within the length limit or not +typedef std::vector < HPhrase > HPhraseVector; + +// SentenceVertices represents all vertices that have the same positioning of all extracted phrases +// The key of the std::map is the English index and the value is a std::set of the foreign ones +typedef std::map <int, std::set<int> > HSenteceVertices; + + +#endif /* HIERARCHICAL_H_ */ |