C

install swig and box2d-py for windows

install swig and box2d-py for windows

Posted by xuepro on January 20, 2020

I encountered an error when I want to use the lunar_lander environment in gym. The error is :

error: “module ‘gym.envs.box2d’ has no attribute ‘LunarLander’”

I searched on internet and found the solution:

  1. download swig for windows, unzip to a folder and add the folder to the PATH environment variable.

  2. pip install box2d-py

Refer to :

Installing pocketsphinx python module: command ‘swig.exe’ failed

AttributeError: module ‘gym.envs.box2d’ has no attribute ‘BipedalWalker’


支付宝打赏 微信打赏

您的打赏是对我最大的鼓励!