-
Notifications
You must be signed in to change notification settings - Fork 8.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Specific Plans for Replacing MuJoCo Environments With PyBullet #2366
Comments
@benelot if you'd be willing to help with this process, specifically regarding bugs that will inevitable arise after the beta is released and making the environments as similar to the MuJuCo ones as possible, I would greatly appreciate it. |
So it turns out that Pybullet natively includes some of these environments: https://docs.google.com/document/d/10sXEhzFRSnvFcl3XxNGhnD4N2SedqwdAvK3dsihxVUA/edit# (page 67). I have no idea if they wrote them from scratch or if they took them another source, or if they're more maintained than any of those other sources. Based on the included environments I'm assuming they're from the first repo. I would rather these live in Gym, I'll create an issue with them. |
So apparently the PyBullet repo (https://github.com/bulletphysics/bullet3) has disabled issues and only allows for PRs, which they don't generally respond to? @Rohan138 figure out if we should be stealing code from them or from the other sources and then create a PR there to remove the environments we're including from bullet master. |
I can certainly provide clarification with some of the issues here: I started a rewrite of the MuJoCo envs based on pybullet to make them base on an open source physics framework (open science and stuff). Erwin Coumans from pybullet started providing support for some google internal envs, so I asked him if he would be willing to merge some of my code into his repository. I am not sure if they are still there of if my code is now the only source of truth. My note on some envs not being similar to the original MuJoCo ones is related to the fact that I did not find a document explaining some of the mujoco observations, so I could not find corresponding observations in pybullet. If you can help me with that, we can certainly find correspondences. I would certainly be willing to help with this process if I can, given that it has always been my goal to provide alternative open envs for the MuJoCo ones. |
@benelot could you please email me at [email protected]? |
@jkterry1 Sent! Did you get it? |
yep :) (for those watching I just wanted to set up a zoom meeting) |
Just mentioning #2345 here; if we want drop-in replacements where the only change required is pip install gym[phys3d], then we may have to deal with collisions in environment ids. In general, I think this PR would benefit from the plugins system proposed. |
Two things from the exchanges with @benelot needs to be mentioned for those watching because I don't believe it's been publicly documented:
|
Hello I also wanted to chime in. This is something I was briefly interested in awhile ago but didn't really go anywhere with. I'm not quite sure what exactly you mean by a "drop in replacement" I think it will probably be possible to make the observation space in bullet mimic what the current MuJoCo environments, but I think it will be much more difficult to get the performance of RL algorithms across similar environments in the two different sims to be roughly equivalent. Like I mentioned on the discord the contact / constraint model between the two simulators is very different, although we can tweak the parameters in bullet to try to better match what MuJoCo does. I made a small example doing this here: https://gist.github.com/sgillen/7674fe6b8254aa512f5091367719fef2 which may be interesting if replicating the MuJoCo envs as close as possible is necessary. Another question I have is (and I mean this as a genuine question) why replicate the Mujoco environments exactly in the first place? Another option might be to try and upgrade / update the environments that @benelot developed / that live in pybullet_envs. I think those environments are also widely used at this point, but I have no numbers on that. |
Also, you may be aware of these already but I thought I'd bring them up just in case:
|
Related stuff… https://deepmind.com/blog/announcements/mujoco Maybe we can still keep MuJoCo after all. |
Closed in favor of #2456 |
This is specifically for the MuJoCo class environments, not the robotic class environments that depend on MuJoCo (those will be replaced too, but that's a future problem).
The plan is to create a phys3d class for the pybullet replacement environments (since they aren't MuJoCo) with drop in replacements. Initially the environments will be unversioned and will have a warning message saying that they're beta. Once they've been thoroughly tested by the community to make sure that they're truly drop in replacements we'll add versioning to them and remove the MuJoCo class of environments.
For specific environments, the major source is is https://github.com/benelot/pybullet-gym. However, this repo has problems:
-It doesn't have the Humanoid Standup or Swimmer environments
-It says that the Walker2d and HalfCheetah environments are not similar to the reference implementations
This brings us to the lesser used source:
https://github.com/benelot/bullet-gym (which by the same guy, but is unmaintained and according to the environment description is the experimental version of the above repo). This is notable in that it has the missing Humanoid Standup and Swimmer environments.
The plan accordingly is for @Rohan138 to add the pybullet environments that replace MuJoCo ones to a new phys3d class from the first repo (it has many more than are included in Gym and I don't want to include new environments) and swimmer and humanoid from the second repo. Once these are in, we would greatly appreciate PRs that make the environments closer to drop in replacements for those in Gym and contributors testing these thoroughly.
The text was updated successfully, but these errors were encountered: