Kursinnhold
Introduction to NLP
Introduction to NLP
2. Stemming and Lemmatization
Challenge: Stemming the Tokens
Oppgave
Swipe to start coding
Your task is the following:
- Import Porter Stemmer.
- Convert
text
to lowercase. - Tokenize the
text
string. - Load English stop words.
- Filter out the stop words using list comprehension.
- Create a stemmer object.
- Stem the tokens using list comprehension.
Løsning
Alt var klart?
Takk for tilbakemeldingene dine!
Seksjon 2. Kapittel 2
Challenge: Stemming the Tokens
Oppgave
Swipe to start coding
Your task is the following:
- Import Porter Stemmer.
- Convert
text
to lowercase. - Tokenize the
text
string. - Load English stop words.
- Filter out the stop words using list comprehension.
- Create a stemmer object.
- Stem the tokens using list comprehension.
Løsning
Alt var klart?
Takk for tilbakemeldingene dine!
Seksjon 2. Kapittel 2