forked from macanv/BERT-BiLSTM-CRF-NER
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrun.py
41 lines (28 loc) · 692 Bytes
/
run.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
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
运行 BERT NER Server
#@Time : 2019/1/26 21:00
# @Author : MaCan ([email protected])
# @File : run.py
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
# sys.path.append('.')
def start_server():
from bert_base.server import BertServer
from bert_base.server.helper import get_run_args
args = get_run_args()
print(args)
server = BertServer(args)
server.start()
server.join()
def start_client():
pass
# def train_ner():
# from bert_lstm_ner import main
# args =
# main()
if __name__ == '__main__':
start_server()