cleantext module can not be imported on google colab pro

Viewed 22

In google colab, I could install and import clean-text module well, but after changing the account to google colab pro, this module can not be imported. I've tried these lines of code for installing:

!pip install -q clean-text[gpl]

and

!conda install clean-text[gpl]

and

!pip install cleantext

and I imported it like this:

import cleantext

or

from cleantext import clean

but I got this error:

ModuleNotFoundError: No module named 'cleantext'

How can I fix this on google colab pro?

2 Answers

If it is not importing directly from pip then, You can use google drive to import the library. First connect drive to colab. second upload library source files in the drive. third import library in colab notebook.

Install this module in this way:

!pip install clean_text
Related