Skip to content

stopwords.words("English") raises OS Error #6

@piermarcobarbe

Description

@piermarcobarbe

When executing:
from nltk.corpus import stopwords
stopwords_verbs = ['say', 'get', 'go', 'know', 'may', 'need', 'like', 'make', 'see', 'want', 'come', 'take', 'use', 'would', 'can']
stopwords_other = ['one', 'mr', 'bbc', 'image', 'getty', 'de', 'en', 'caption', 'also', 'copyright', 'something']
my_stopwords = stopwords.words('English') + stopwords_verbs + stopwords_other
An error occurs:
OSError: No such file or directory: '/home/jovyan/nltk_data/corpora/stopwords/English'

Using, instead, stopwords.words("english") works fine.

The lines can be found in the notebook "LDA-BBC".

Running notebook from Jupyter on Docker.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions