理论上可以通过 Python 下载节的模型,如下所示(mirror):
import stanza
stanza.download('en') # This downloads the English models for the neural pipeline
但是,无法从我的计算机访问斯坦福服务器:
(neural-parser2) dernoncourt@ilcompn0:~/temp/stanza$ python
Python 3.6.7 (default, Oct 25 2018, 09:16:13)
[GCC 5.4.0 20160609] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import stanza
>>> stanza.download('en')
Downloading https://raw.githubusercontent.com/stanfordnlp/stanza-resources/master/resources_1.0.0.json: 115kB [00:00, 24.5MB/s]
2020-07-07 21:08:34 INFO: Downloading default packages for language: en (English)...
Traceback (most recent call last):
File "/mnt/ilcodisk1/user/dernoncourt/pyenv/neural-parser2/lib/python3.6/site-packages/urllib3/connection.py", line 160, in _new_conn
(self._dns_host, self.port), self.timeout, **extra_kw
File "/mnt/ilcodisk1/user/dernoncourt/pyenv/neural-parser2/lib/python3.6/site-packages/urllib3/util/connection.py", line 84, in create_connection
raise err
File "/mnt/ilcodisk1/user/dernoncourt/pyenv/neural-parser2/lib/python3.6/site-packages/urllib3/util/connection.py", line 74, in create_connection
sock.connect(sa)
TimeoutError: [Errno 110] Connection timed out
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/mnt/ilcodisk1/user/dernoncourt/pyenv/neural-parser2/lib/python3.6/site-packages/urllib3/connectionpool.py", line 677, in urlopen
chunked=chunked,
File "/mnt/ilcodisk1/user/dernoncourt/pyenv/neural-parser2/lib/python3.6/site-packages/urllib3/connectionpool.py", line 392, in _make_request
conn.request(method, url, **httplib_request_kw)
如何手动下载节的模型?我希望节的模型存储在多个服务器中。
我用stanza==1.0.1。
肥皂起泡泡
相关分类