File size: 509 Bytes
fd49381
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
//
//  SentenceAlignment.cpp
//  moses
//
//  Created by Hieu Hoang on 26/07/2012.
//  Copyright 2012 __MyCompanyName__. All rights reserved.
//

#include <iostream>
#include "util/string_stream.hh"
#include "SentenceAlignment.h"

namespace tmmt
{
std::string SentenceAlignment::getTargetString(const Vocabulary &vocab) const
{
  util::StringStream strme;
  for (size_t i = 0; i < target.size(); ++i) {
    const WORD &word = vocab.GetWord(target[i]);
    strme << word << " ";
  }
  return strme.str();
}

}