How to install NLTK modules in Heroku

后端 未结 4 1865
独厮守ぢ
独厮守ぢ 2021-02-20 08:11

Hey i\'d like to install the NLTK pos_tag on my Heroku server. How can i do so. Please give me the steps as im new to the Heroku server system.

4条回答
  •  不思量自难忘°
    2021-02-20 08:39

    You need to follow the below steps.

    1. nltk.txt needs to present at the root folder
    2. Add the modules you want to download like punkt, stopwords as separate row items
    3. Change the line ending from windows to UNIX

    Changing the line ending is a very important step. Can be easily done through Sublime Text or Notepad++. In Sublime Text, it can done from the View menu, then Line Endings.

    Hope this helps

提交回复
热议问题