[英]I have installed Anaconda and I have installed pygame as well, but still got an error ModuleNotFoundError: No module named 'pygame'
So, I have installed Anaconda3 64 bit and TensorFlow, matplotlib, and I have also installed pygame, but I still got an error saying ModuleNotFoundError: No module named 'pygame'
and ModuleNotFoundError: No module named 'pygame'
所以,我已经安装了 Anaconda3 64 位和 TensorFlow、matplotlib,并且我还安装了 pygame,但我仍然得到一个错误,说
ModuleNotFoundError: No module named 'pygame'
ModuleNotFoundError: No module named 'pygame'
In Anaconda, I have made a new environment and that has all of the packages I have installed and I open jupyter notebook from this environment.在 Anaconda 中,我创建了一个新环境,其中包含我已安装的所有软件包,并从该环境中打开 jupyter notebook。 Still the error is there.
错误仍然存在。
In Anaconda command prompt:在 Anaconda 命令提示符下:
(base) C:\Users\Eszter>pip install pygame
Requirement already satisfied: pygame in c:\users\eszter\anaconda3\lib\site-packages (2.0.1)
Part of the code is this: **部分代码是这样的:**
import numpy as np
import matplotlib.pyplot as plt
import pygame
from agent import Agent
** **
No module named 'pygame'
No module named 'agent'
Anybody can help me with this?任何人都可以帮助我吗? I really appreciated it.
我真的很感激。
Use conda install
from anaconda prompt instead of pip
从 anaconda 提示符使用 conda
conda install
而不是pip
conda install pygame
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.