Commit Graph

36 Commits

Author SHA1 Message Date
Hieu Hoang
6249432407 beautify 2013-05-29 18:16:15 +01:00
Hieu Hoang
e3dd3a8d2c namespace all classes in mert directory 2012-06-30 20:23:45 +01:00
Tetsuo Kiso
9c9d88a78a Avoid "using namespace std" in headers. 2012-05-10 07:51:05 +09:00
Tetsuo Kiso
49a4be2899 Reduce the number of calling the numeric_limits constructor.
- Create a test module for Point.
- Add test cases.
2012-04-12 05:19:11 +09:00
Tetsuo Kiso
24b1314d90 Fix indentation. 2012-03-31 10:43:54 +09:00
Tetsuo Kiso
59f755587a Prefix a private member of Optimizer with "m_". 2012-03-31 10:39:59 +09:00
tosch
fab03f5a6e added an (optional) positivity constraint to MERT 2012-03-30 11:50:23 +02:00
Tetsuo Kiso
54233d3270 Create files for OptimizerFactory class; add the unit test. 2012-03-18 13:08:38 +09:00
Tetsuo Kiso
38c662d4e0 Pass parameters by const reference. 2012-03-18 12:32:11 +09:00
Tetsuo Kiso
e7a2483b22 mert: Prefix private members with "m_" except TER.
Squashed commit of the following:

- Clean up PRO.
- Clean up ScoreStats.
- Clean up ScoreData.
- Clean up ScoreArray.
- Remove unnecessary headers.
- Clean up ScopedVector.
- Clean up Point.
- Clean up PerScorer.
- Clean up Optimizer.
- Clean up MergeScorer.
- Clean up InterpolatedScorer.
- Clean up FileStream.
- Clean up FeatureStats.
- Remove inefficient string concatenation.
- Clean up FeatureData.
- Clean up FeatureArray.
- Clean up Data.
2012-03-10 17:12:34 +09:00
Tetsuo Kiso
47ac8a474d Change the naming conventions for the guard macros; Rename TER directory.
This change might be useful to avoid duplicating the names.
The reason is that although MERT programs are standalone
applications, some header files such as data.h and
point.h have common guard macro names like "DATA_H" and
"POINT_H", and this is not good naming conventions
when you want to include external headers.
Some files actually include headers in Moses and KenLM's util.
2012-02-20 09:46:08 +09:00
Barry Haddow
62d7d034bb Fix sharding bug 2012-02-08 17:11:56 +00:00
Tetsuo Kiso
8e1bf6d7d1 Pass std::string objects by const reference instead of by value. 2012-02-01 16:46:36 +09:00
Tetsuo Kiso
29c16d252a Minimize using #include headers in headers.
Should use it in .cpp files.
2011-11-14 15:15:30 +09:00
Tetsuo Kiso
be1506e759 Use passing objects by const references not passing by their values. 2011-11-14 14:00:47 +09:00
Tetsuo Kiso
eecfb171da Fix usage of whitespaces for Optimizers. 2011-11-12 18:47:31 +09:00
Tetsuo Kiso
43beb88df5 Fix constructors of scorer classes and optimizer classes.
Using public const members is not good idea.
It should be initialized in private by constructors.
2011-11-12 10:16:31 +09:00
Tetsuo Kiso
fdb83b0f6d Put constructor and destructor into private for Factory class 2011-11-12 09:56:21 +09:00
Tetsuo Kiso
ce9a628ed0 Remove unnecessary semicolons used in end of member functions. 2011-11-12 09:40:01 +09:00
Tetsuo Kiso
664ffe0130 Fix indentation. 2011-11-12 09:24:19 +09:00
Tetsuo Kiso
68315d6407 Fix class, function, and implementation comments format.
Functions comments should be placed in their declarations.
2011-11-12 08:58:23 +09:00
Tetsuo Kiso
4f6d022fe7 Add comments to mark the end of #define guards. 2011-11-12 07:59:50 +09:00
Tetsuo Kiso
c2121695c2 Fix memory leaks in mert. 2011-11-11 20:40:59 +09:00
phkoehn
1bd74fc87f added random directions [Cer&al.,2008] and historic best as starting points [Foster&Kuhn,2009] to MERT
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@4086 1f5c12ca-751b-0410-a591-d2e778427230
2011-07-23 00:24:45 +00:00
hieuhoang1972
148c1e8305 run beautify.perl. Consistent formatting for .h & .cpp files
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@3899 1f5c12ca-751b-0410-a591-d2e778427230
2011-02-24 12:42:19 +00:00
bhaddow
86772c27e2 Fixed return of non-initialised variable
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@1782 1f5c12ca-751b-0410-a591-d2e778427230
2008-05-17 13:24:09 +00:00
jfouet
e9df80a05c bugfixes
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@1726 1f5c12ca-751b-0410-a591-d2e778427230
2008-05-16 10:57:24 +00:00
jfouet
b231ffc8b1 add Types.h to unify the typedefs
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@1713 1f5c12ca-751b-0410-a591-d2e778427230
2008-05-15 19:09:01 +00:00
bhaddow
c0643d47f2 Add scorer factory. Fix compile error in Optimizer
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@1706 1f5c12ca-751b-0410-a591-d2e778427230
2008-05-15 16:03:49 +00:00
jfouet
b0ee845d7e various small fixes
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@1702 1f5c12ca-751b-0410-a591-d2e778427230
2008-05-15 14:17:34 +00:00
jfouet
c66aec9e83 implementation of the main
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@1698 1f5c12ca-751b-0410-a591-d2e778427230
2008-05-15 14:04:42 +00:00
jfouet
bfe3661110 implementation of optimization on a subset of the parameters + debug mode in the makefile
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@1695 1f5c12ca-751b-0410-a591-d2e778427230
2008-05-15 10:57:20 +00:00
jfouet
cff8d4702b add some sanity checks
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@1668 1f5c12ca-751b-0410-a591-d2e778427230
2008-05-14 16:19:00 +00:00
jfouet
cb5305ab46 implementation of LineOptimizer
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@1659 1f5c12ca-751b-0410-a591-d2e778427230
2008-05-14 14:25:07 +00:00
jfouet
558c8bd9b7 fix compilation of Optimizer
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@1651 1f5c12ca-751b-0410-a591-d2e778427230
2008-05-14 12:49:45 +00:00
jfouet
f9448b76a0 objet code for the Optimzer algorithm
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@1637 1f5c12ca-751b-0410-a591-d2e778427230
2008-05-14 11:00:59 +00:00