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
path: root/moses
diff options
context:
space:
mode:
authorredpony <redpony@1f5c12ca-751b-0410-a591-d2e778427230>2006-10-03 22:41:39 +0400
committerredpony <redpony@1f5c12ca-751b-0410-a591-d2e778427230>2006-10-03 22:41:39 +0400
commit1753207076058ee40e8ac5a1bf1f39f0e68d0ef5 (patch)
tree8c9b037f12dad1501c76bf9411f945ac2da8d716 /moses
parent38cef854abe03df882a3401a1200aa0046efb1dc (diff)
get ride of internal language model code since it is no longer possible to enable it.
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@841 1f5c12ca-751b-0410-a591-d2e778427230
Diffstat (limited to 'moses')
-rwxr-xr-xmoses/src/LanguageModel.cpp2
-rw-r--r--moses/src/LanguageModelSingleFactor.cpp2
-rwxr-xr-xmoses/src/NGramCollection.cpp54
-rwxr-xr-xmoses/src/NGramCollection.h46
-rwxr-xr-xmoses/src/NGramNode.h80
-rwxr-xr-xmoses/src/TypeDef.h3
6 files changed, 0 insertions, 187 deletions
diff --git a/moses/src/LanguageModel.cpp b/moses/src/LanguageModel.cpp
index 01336700d..b6efd431e 100755
--- a/moses/src/LanguageModel.cpp
+++ b/moses/src/LanguageModel.cpp
@@ -24,8 +24,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
#include <iostream>
#include <sstream>
-#include "NGramNode.h"
-
#include "LanguageModel.h"
#include "TypeDef.h"
#include "Util.h"
diff --git a/moses/src/LanguageModelSingleFactor.cpp b/moses/src/LanguageModelSingleFactor.cpp
index 2ac788269..8eddb2561 100644
--- a/moses/src/LanguageModelSingleFactor.cpp
+++ b/moses/src/LanguageModelSingleFactor.cpp
@@ -24,8 +24,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
#include <iostream>
#include <sstream>
-#include "NGramNode.h"
-
#include "LanguageModelSingleFactor.h"
#include "TypeDef.h"
#include "Util.h"
diff --git a/moses/src/NGramCollection.cpp b/moses/src/NGramCollection.cpp
deleted file mode 100755
index 1dec46677..000000000
--- a/moses/src/NGramCollection.cpp
+++ /dev/null
@@ -1,54 +0,0 @@
-// $Id$
-
-/***********************************************************************
-Moses - factored phrase-based language decoder
-Copyright (C) 2006 University of Edinburgh
-
-This library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Lesser General Public
-License as published by the Free Software Foundation; either
-version 2.1 of the License, or (at your option) any later version.
-
-This library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-Lesser General Public License for more details.
-
-You should have received a copy of the GNU Lesser General Public
-License along with this library; if not, write to the Free Software
-Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
-***********************************************************************/
-
-#include "NGramCollection.h"
-#include "NGramNode.h"
-
-NGramCollection::~NGramCollection()
-{
- clear();
-}
-
-NGramNode *NGramCollection::GetOrCreateNGram(const Factor *factor)
-{
- NGramCollection::iterator iter = this->find(factor);
- if (iter == NGramCollection::end())
- {
- return &((*this)[factor] = NGramNode());
- }
- else
- {
- return &(iter->second);
- }
-}
-
-NGramNode *NGramCollection::GetNGram(const Factor *factor)
-{
- NGramCollection::iterator iter = this->find(factor);
- return (iter == NGramCollection::end()) ? NULL : &(iter->second) ;
-}
-
-const NGramNode *NGramCollection::GetNGram(const Factor *factor) const
-{
- NGramCollection::const_iterator iter = this->find(factor);
- return (iter == NGramCollection::end()) ? NULL : &(iter->second) ;
-}
-
diff --git a/moses/src/NGramCollection.h b/moses/src/NGramCollection.h
deleted file mode 100755
index 6179c7e4f..000000000
--- a/moses/src/NGramCollection.h
+++ /dev/null
@@ -1,46 +0,0 @@
-// $Id$
-
-/***********************************************************************
-Moses - factored phrase-based language decoder
-Copyright (C) 2006 University of Edinburgh
-
-This library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Lesser General Public
-License as published by the Free Software Foundation; either
-version 2.1 of the License, or (at your option) any later version.
-
-This library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-Lesser General Public License for more details.
-
-You should have received a copy of the GNU Lesser General Public
-License along with this library; if not, write to the Free Software
-Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
-***********************************************************************/
-
-#pragma once
-
-#include <map>
-#include <vector>
-
-class Factor;
-class NGramNode;
-
-typedef std::vector<const Factor*> FactorVector;
-
-class NGramCollection : public std::map<const Factor*, NGramNode>
-{
-
-public:
- NGramCollection()
- {
- }
- ~NGramCollection();
-
- NGramNode *GetOrCreateNGram(const Factor *factor);
- NGramNode *GetNGram(const Factor *factor);
- const NGramNode *GetNGram(const Factor *factor) const;
-
-};
-
diff --git a/moses/src/NGramNode.h b/moses/src/NGramNode.h
deleted file mode 100755
index c79d4d678..000000000
--- a/moses/src/NGramNode.h
+++ /dev/null
@@ -1,80 +0,0 @@
-// $Id$
-
-/***********************************************************************
-Moses - factored phrase-based language decoder
-Copyright (C) 2006 University of Edinburgh
-
-This library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Lesser General Public
-License as published by the Free Software Foundation; either
-version 2.1 of the License, or (at your option) any later version.
-
-This library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-Lesser General Public License for more details.
-
-You should have received a copy of the GNU Lesser General Public
-License along with this library; if not, write to the Free Software
-Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
-***********************************************************************/
-
-#pragma once
-
-#include "NGramCollection.h"
-
-class NGramNode
-{
-protected:
- float m_score, m_logBackOff;
- NGramCollection m_map;
- NGramNode *m_rootNGram;
-public:
- NGramNode()
- {
- }
- NGramCollection *GetNGramColl()
- {
- return &m_map;
- }
- //const NGramCollection *GetNGramColl() const
- //{
- // return &m_map;
- //}
- const NGramNode *GetNGram(const Factor *factor) const
- {
- return m_map.GetNGram(factor);
- }
- NGramNode *GetNGram(const Factor *factor)
- {
- return m_map.GetNGram(factor);
- }
-
- const NGramNode *GetRootNGram() const
- {
- return m_rootNGram;
- }
- void SetRootNGram(NGramNode *rootNGram)
- {
- m_rootNGram = rootNGram;
- }
-
- float GetScore() const
- {
- return m_score;
- }
- float GetLogBackOff() const
- {
- return m_logBackOff;
- }
- void SetScore(float score)
- {
- m_score = score;
- }
- void SetLogBackOff(float logBackOff)
- {
- m_logBackOff = logBackOff;
- }
-
-};
-
diff --git a/moses/src/TypeDef.h b/moses/src/TypeDef.h
index 4a744ffda..905e5de34 100755
--- a/moses/src/TypeDef.h
+++ b/moses/src/TypeDef.h
@@ -56,15 +56,12 @@ const size_t DEFAULT_VERBOSE_LEVEL = 1;
# ifdef HAVE_SRILM
# define LM_SRI 1
-# undef LM_INTERNAL
# else
# undef LM_SRI
-# define LM_INTERNAL 1
# endif
# ifdef HAVE_IRSTLM
# define LM_IRST 1
-# undef LM_INTERNAL
# undef LM_SRI
# endif