Added some basic gym env registration
Thought I'd take a stab at #297
Added some simple registration of sm.Scene objects with sm.RLEnv
scene = sm.Scene() # this could also be loaded in
sm.RLEnv.register("SimulateLunarLander-v0", scene, frame_skip=1)
env = gym.make("SimulateLunarLander-v0")
Right now it just uses the initial scene object, but maybe it should copy it before.
Let me know if this is useful! @natolambert
The docs for this PR live here. All of your documentation changes will be reflected on that endpoint.
Hi @shyamsn97 ! This is a great start. Sorry for the delay, I'm wrapping my head around if we want to do this in specific examples, have a general API, or just include it in the docs.
Happy to hear any thoughts from the community, and I'll write up my thoughts soon too.
Hey, thanks for reviewing! Sorry it’s failing, will fix that soon. Also yeah I think having a general api for registering envs makes sense because if a user wanted to write their own registration method it’s not too straightforward (normally I’d pass Scene into the registration kwargs, but it fails because socket can’t be pickled). But I also see how including a small snippet in the docs could work
Yeah I'm happy to have it in multiple places for now. Two that seem most specific are in the rl examples or in the docs under advanced usage. Happy to answer specifics on how to do this.
I'm thinking add a new example so it's easier to find!
Ah the tests seem to be failing because of gym I can think about this.