Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/moses-smt/mosesdecoder.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHieu Hoang <hieu@hoang.co.uk>2013-05-29 21:16:15 +0400
committerHieu Hoang <hieu@hoang.co.uk>2013-05-29 21:16:15 +0400
commit6249432407af8730c10bccc7894c0725fcaf5e47 (patch)
tree3ac1f094b9fdc199b04bc5ef209ce00e3596e37d /mert/FeatureArray.h
parent59bd7deb4b6b9c4f7b3b7dbb055783528fbc31ca (diff)
beautify
Diffstat (limited to 'mert/FeatureArray.h')
-rw-r--r--mert/FeatureArray.h44
1 files changed, 33 insertions, 11 deletions
diff --git a/mert/FeatureArray.h b/mert/FeatureArray.h
index 03fe6b40c..f5fc489a2 100644
--- a/mert/FeatureArray.h
+++ b/mert/FeatureArray.h
@@ -36,16 +36,28 @@ public:
FeatureArray();
~FeatureArray();
- void clear() { m_array.clear(); }
+ void clear() {
+ m_array.clear();
+ }
- int getIndex() const { return m_index; }
- void setIndex(const int value) { m_index = value; }
+ int getIndex() const {
+ return m_index;
+ }
+ void setIndex(const int value) {
+ m_index = value;
+ }
- FeatureStats& get(std::size_t i) { return m_array.at(i); }
- const FeatureStats& get(std::size_t i) const { return m_array.at(i); }
+ FeatureStats& get(std::size_t i) {
+ return m_array.at(i);
+ }
+ const FeatureStats& get(std::size_t i) const {
+ return m_array.at(i);
+ }
- void add(FeatureStats& e) { m_array.push_back(e); }
+ void add(FeatureStats& e) {
+ m_array.push_back(e);
+ }
//ADDED BY TS
void swap(std::size_t i, std::size_t j) {
@@ -59,13 +71,23 @@ public:
void merge(FeatureArray& e);
- std::size_t size() const { return m_array.size(); }
+ std::size_t size() const {
+ return m_array.size();
+ }
- std::size_t NumberOfFeatures() const { return m_num_features; }
- void NumberOfFeatures(std::size_t v) { m_num_features = v; }
+ std::size_t NumberOfFeatures() const {
+ return m_num_features;
+ }
+ void NumberOfFeatures(std::size_t v) {
+ m_num_features = v;
+ }
- std::string Features() const { return m_features; }
- void Features(const std::string& f) { m_features = f; }
+ std::string Features() const {
+ return m_features;
+ }
+ void Features(const std::string& f) {
+ m_features = f;
+ }
void savetxt(std::ostream* os);
void savebin(std::ostream* os);