Change nltk.download() path directory from default ~/ntlk_data

后端 未结 4 1947
生来不讨喜
生来不讨喜 2021-02-05 07:30

I was trying to download/update python nltk packages on a computing server and it returned this [Errno 122] Disk quota exceeded: error.

Specifi

4条回答
  •  粉色の甜心
    2021-02-05 08:18

    You may also use nltk.download_shell() and follow the interactive steps as shown below.

    Also use nltk.data.path.append('/your/new/data/directory/path') to instruct nltk to to load data from new data path.

提交回复
热议问题