How to solve the 'Attribute Error' in gym when colab is using GPU

Viewed 390

here is my code:

!pip install box2d-py==2.3.8

import gym

env = gym.make('CarRacing-v0')

The err-msg is:

AttributeError: module 'gym.envs.box2d' has no attribute 'CarRacing'

screenshot

But the same code is ok when colab is using the CPU environment.

0 Answers
Related