-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrun_nlptext.py
59 lines (39 loc) · 1.26 KB
/
run_nlptext.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
from pprint import pprint
from nlptext.base import BasicObject
from nlptext.base import BasicObject
########### Wiki ###########
CORPUSPath = 'corpus/fudan/'
Corpus2GroupMethod = 'Dir'
Group2TextMethod = 'file'
Text2SentMethod = 'whole'
Sent2TokenMethod = ' '
TOKENLevel = 'word'
min_token_freq = 1
use_hyper = []
anno = False
anno_keywords = {}
BasicObject.INIT(CORPUSPath,
Corpus2GroupMethod,
Group2TextMethod,
Text2SentMethod,
Sent2TokenMethod, TOKENLevel, min_token_freq = min_token_freq,
use_hyper = use_hyper,
anno = False, anno_keywords = anno_keywords)
from nlptext.base import BasicObject
CORPUSPath = 'corpus/newsgroup/'
Corpus2GroupMethod = 'Dir'
Group2TextMethod = 'file'
Text2SentMethod = 'whole'
Sent2TokenMethod = 'pos_en'
TOKENLevel = 'word'
min_token_freq = 1
use_hyper = ['pos_en']
anno = False
anno_keywords = {}
BasicObject.INIT(CORPUSPath,
Corpus2GroupMethod,
Group2TextMethod,
Text2SentMethod,
Sent2TokenMethod, TOKENLevel, min_token_freq = min_token_freq,
use_hyper = use_hyper,
anno = False, anno_keywords = anno_keywords)