forked from HIT-SCIR/ltp
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix bug in erase space after split sentence
- Loading branch information
Showing
5 changed files
with
13 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
segmentor-model = new_ltp_data/cws.model | ||
postagger-model = new_ltp_data/pos.model | ||
parser-model = new_ltp_data/parser.model | ||
ner-model = new_ltp_data/ne_data | ||
srl-data = new_ltp_data/srl/ | ||
segmentor-model = ltp_data/cws.model | ||
postagger-model = ltp_data/pos.model | ||
parser-model = ltp_data/parser.model | ||
ner-model = ltp_data/ner.model | ||
srl-data = ltp_data/srl/ |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,17 @@ | ||
#include "SplitSentence.h" | ||
//#include "SentenceIterator.h" | ||
#include <string.h> | ||
#include "strutils.hpp" | ||
#include "sentsplit.hpp" | ||
|
||
//using namespace util; | ||
|
||
int SplitSentence( const std::string& strPara, std::vector<std::string>& vecSentence ) { | ||
ltp::Chinese::split_sentence(strPara, vecSentence); | ||
/*StringReader sr( strPara.c_str() ); | ||
Separator sep; | ||
sentence_iterator si(&sr, sep), send; | ||
vecSentence.clear(); | ||
while( si != send ) { | ||
if(strlen(*si) < 400){ | ||
vecSentence.push_back( *si ); | ||
} | ||
si++; | ||
}*/ | ||
|
||
for (int i = 0; i < vecSentence.size(); ++ i) { | ||
vecSentence[i] = ltp::strutils::chomp(vecSentence[i]); | ||
} | ||
|
||
return 1; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.