I have install a module named "mplsoccer" in my Ubuntu to work on soccer visualization. But everytime I run, it shows: ModuleNotFoundError: No module named ‘mplsoccer’.
I ran my code on Visual Studio Code. I also tried PyCharm. In Pycharm, in the project interpreter section it shows the ‘mplsoccer’ package same as it shows ‘pandas’. But still I can’t find a solution.
2
Answers
I would recommend using a package manager and virtual environment to install your packages. This ensures that all your packages are installed in one place and there are no dependency issues.
For example, using miniconda3 and assuming it is installed already. mplsoccer is available via conda-forge which you can check by searching for packages here: https://anaconda.org/search?q=mplsoccer
conda create --name <name_of_env> python=<version_#>
(version_# must be > 3.6 for mplsoccer)conda activate <name_of_env>
conda install -c conda-forge mplsoccer
Try the below steps:
Then try: