Skip to content
Snippets Groups Projects
Commit 5a987b3e authored by Franck Dary's avatar Franck Dary
Browse files

Fixed lemmatization

parent 7c956acf
No related branches found
No related tags found
No related merge requests found
...@@ -383,10 +383,7 @@ void Oracle::createDatabase() ...@@ -383,10 +383,7 @@ void Oracle::createDatabase()
char b4[1024]; char b4[1024];
while (fscanf(fd, "%[^\t]\t%[^\t]\t%[^\t]\t%[^\n]\n", b1, b2, b3, b4) == 4) while (fscanf(fd, "%[^\t]\t%[^\t]\t%[^\t]\t%[^\n]\n", b1, b2, b3, b4) == 4)
{
oracle->data[std::string(b1) + std::string("_") + b2] = b3; oracle->data[std::string(b1) + std::string("_") + b2] = b3;
oracle->data[std::string(b1) + std::string("_??")] = b3;
}
}, },
[](Config & c, Oracle * oracle) [](Config & c, Oracle * oracle)
{ {
...@@ -397,12 +394,6 @@ void Oracle::createDatabase() ...@@ -397,12 +394,6 @@ void Oracle::createDatabase()
if(lemma.empty()) if(lemma.empty())
lemma = oracle->data[noAccentLower(form) + "_" + pos]; lemma = oracle->data[noAccentLower(form) + "_" + pos];
if(lemma.empty())
lemma = oracle->data[form + "_??"];
if(lemma.empty())
lemma = oracle->data[noAccentLower(form) + "_??"];
if(lemma.empty()) if(lemma.empty())
return std::string("NOTFOUND"); return std::string("NOTFOUND");
else else
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment