update sample query to read ini file with relative file paths

This commit is contained in:
Hieu Hoang 2013-12-31 16:52:47 +00:00
parent a9c81857c1
commit 02b78d72d9

View File

@ -95,10 +95,16 @@ void LanguageModelDALM::Load()
/////////////////////
// READING INIFILE //
/////////////////////
string inifile= m_filePath + "/dalm.ini";
string model; // Path to the double-array file.
string words; // Path to the vocabulary file.
string wordstxt; //Path to the vocabulary file in text format.
read_ini(m_filePath.c_str(), model, words, wordstxt);
read_ini(inifile.c_str(), model, words, wordstxt);
model = m_filePath + "/" + model;
words = m_filePath + "/" + words;
wordstxt = m_filePath + "/" + wordstxt;
UTIL_THROW_IF(model.empty() || words.empty() || wordstxt.empty(),
util::FileOpenException,