Skip to content

Commit

Permalink
修改配置文件
Browse files Browse the repository at this point in the history
  • Loading branch information
jiangzhonglian committed Sep 4, 2020
1 parent 748b3e5 commit 1036c7d
Showing 1 changed file with 22 additions and 10 deletions.
32 changes: 22 additions & 10 deletions config/setting.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,21 +5,33 @@
'''

class TextNER(object):
DEBUG = False
path_root = "/home/apachecn/jiangzhonglian"
DEBUG = True
if DEBUG:
path_root = "/Users/jiangzhonglian/data/nlp/命名实体识别/data"
path_root = "data/NER3"
chunk_tags = ['O', 'B-ORG', 'I-ORG',
'B-Po_VIEW', 'I-Po_VIEW',
'B-Mi_VIEW', 'I-Mi_VIEW',
'B-Ne_VIEW', 'I-Ne_VIEW'
]
# chunk_tags = ['O', 'B-TIME', 'I-TIME', 'B-LOCATION', 'I-LOCATION',
# "B-PERSON_NAME", "I-PERSON_NAME", "B-ORG_NAME", "I-ORG_NAME",
# "B-COMPANY_NAME", "I-COMPANY_NAME", "B-PRODUCT_NAME", "I-PRODUCT_NAME"]
# chunk_tags = ['O', 'B-PER', 'I-PER', 'B-LOC', 'I-LOC', "B-ORG", "I-ORG"]
else:
path_root = "data/NER"
chunk_tags = ['O', 'B-PER', 'I-PER', 'B-LOC', 'I-LOC', "B-ORG", "I-ORG"]

path_train = '%s/train_data.data' % path_root
path_test = '%s/test_data.data' % path_root
path_config = '%s/config.pkl' % path_root
path_model = '%s/model.h5' % path_root
path_origin = '%s/origin.txt' % path_root
path_train = '%s/train.txt' % path_root
path_test = '%s/test.txt' % path_root
path_config = '%s/config.pkl' % path_root
path_model = '%s/model.h5' % path_root

# 迭代次数
EPOCHS = 3
# embedding的列数
EPOCHS = 10
# embedding的维度数
EMBED_DIM = 128
# LSTM的列数
# LSTM的维度数
BiLSTM_UNITS = 128


Expand Down

0 comments on commit 1036c7d

Please sign in to comment.