wangpeiyi9979 / informationextractiondemo Goto Github PK
View Code? Open in Web Editor NEW一个关于百度2019语言与智能技术竞赛信息抽取 (http://lic2019.ccf.org.cn/kg) 的简单Demo, 模型采用BERT+CNN ( https://github.com/Wangpeiyi9979/IE-Bert-CNN )。 Demo使用Flask搭建
一个关于百度2019语言与智能技术竞赛信息抽取 (http://lic2019.ccf.org.cn/kg) 的简单Demo, 模型采用BERT+CNN ( https://github.com/Wangpeiyi9979/IE-Bert-CNN )。 Demo使用Flask搭建
Traceback (most recent call last):
File "/home/clife/anaconda2/envs/py36/lib/python3.6/site-packages/flask/app.py", line 2328, in call
return self.wsgi_app(environ, start_response)
File "/home/clife/anaconda2/envs/py36/lib/python3.6/site-packages/flask/app.py", line 2314, in wsgi_app
response = self.handle_exception(e)
File "/home/clife/anaconda2/envs/py36/lib/python3.6/site-packages/flask/app.py", line 1760, in handle_exception
reraise(exc_type, exc_value, tb)
File "/home/clife/anaconda2/envs/py36/lib/python3.6/site-packages/flask/_compat.py", line 36, in reraise
raise value
File "/home/clife/anaconda2/envs/py36/lib/python3.6/site-packages/flask/app.py", line 2311, in wsgi_app
response = self.full_dispatch_request()
File "/home/clife/anaconda2/envs/py36/lib/python3.6/site-packages/flask/app.py", line 1834, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/home/clife/anaconda2/envs/py36/lib/python3.6/site-packages/flask/app.py", line 1737, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/home/clife/anaconda2/envs/py36/lib/python3.6/site-packages/flask/_compat.py", line 36, in reraise
raise value
File "/home/clife/anaconda2/envs/py36/lib/python3.6/site-packages/flask/app.py", line 1832, in full_dispatch_request
rv = self.dispatch_request()
File "/home/clife/anaconda2/envs/py36/lib/python3.6/site-packages/flask/app.py", line 1818, in dispatch_request
return self.view_functionsrule.endpoint
File "/home/clife/Leo/InformationExtractionDemo/app.py", line 14, in IEDemo
ieData = getTriple(text)
File "/home/clife/Leo/InformationExtractionDemo/utils/findTriple.py", line 29, in getTriple
_, triples = model(sen, None, None)
File "/home/clife/anaconda2/envs/py36/lib/python3.6/site-packages/torch/nn/modules/module.py", line 493, in call
result = self.forward(*input, **kwargs)
File "/home/clife/Leo/InformationExtractionDemo/utils/BERT_MUL_CNN.py", line 146, in forward
all_tuples = torch.cat(all_tuples, 0) # (B * tule_num, 1, tuple_max_len, bert_hidden_size)
RuntimeError: expected a non-empty list of Tensors
在预测的时候有时会报这个错误,请问下是什么原因引起的?这个地方是不是应该加个异常处理?
RT
不好意思打扰了,官网数据已经不能下载。数据能分享下吗?[email protected]
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.