Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can't import gym; ModuleNotFoundError: No module named 'gym'

enter image description here

Can't import gym;

ModuleNotFoundError: No module named 'gym'
like image 492
yyt Avatar asked Jan 02 '23 08:01

yyt


1 Answers

It seems to me that you're trying to use https://pypi.org/p/gym.

You'd want to run in the terminal (before typing python, when the $ prompt is visible):

pip install gym

After that, if you run python, you should be able to run import gym.

like image 191
pradyunsg Avatar answered Jan 04 '23 22:01

pradyunsg