udacity / deep-reinforcement-learning

Repo for the Deep Reinforcement Learning Nanodegree program

Home Page:https://www.udacity.com/course/deep-reinforcement-learning-nanodegree--nd893

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

In the bipedal walker, errors occur

BerrySG opened this issue · comments

commented

File "c:\windows\system32\gym\gym\envs\box2d\bipedal_walker.py", line 383, in step
self.joints[0].motorSpeed = float(SPEED_HIP * np.sign(action[0]))
TypeError: only size-1 arrays can be converted to Python scalars

I see the same error on Ubuntu 16.04. Somehow action becomes an array of arrays, so action[0] is actually an array of length 4.

commented

@crobarcro
I`ve solved the problem by reinstall the full version of OpenAI-GYM, it seems that some components are missing then lead to this problem

Thanks, did you do this using pip, or from the gym source package?

commented

@crobarcro I download the whole source package then install

@BerrySG, did you manage to run the notebook and get a policy that actually solves the walker problem? I tried the fix of changing action to action[0], which allowed the notebook to run, but it didn't produce useful policies (the walking just stumbles and falls over). The graph of the score in the online notebook also suggests that the policies are not converging to a good solution like that displayed in the video in https://github.com/udacity/deep-reinforcement-learning/blob/master/ddpg-bipedal/README.md