VinAIResearch / PhoBERT

PhoBERT: Pre-trained language models for Vietnamese (EMNLP-2020 Findings)
MIT License
651 stars 92 forks source link

Connection Error when loading rdrsegmenter #4

Closed nguyentienviet123456 closed 4 years ago

nguyentienviet123456 commented 4 years ago

Using this code

from vncorenlp import VnCoreNLP
rdrsegmenter = VnCoreNLP("/Absolute-path-to/vncorenlp/VnCoreNLP-1.1.1.jar", annotators="wseg", max_heap_size='-Xmx500m') 

and get error

ConnectionError: HTTPConnectionPool(host='127.0.0.1', port=51159): Max retries exceeded with url: /annotators (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x10c11f250>: Failed to establish a new connection: [Errno 61] Connection refused'))

datquocnguyen commented 4 years ago

I haven't got this problem before. Are you deadling with a big file ? if yes, then please split it into smaller ones. It might be the case that the error comes from the vncorenlp python wrapper. You should put this issue to https://github.com/dnanhkhoa/python-vncorenlp