Closed kevinzakka closed 3 years ago
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project (if not, look below for help). Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).
:memo: Please visit https://cla.developers.google.com/ to sign.
Once you've signed (or fixed any issues), please reply here with @googlebot I signed it!
and we'll verify it.
ℹ️ Googlers: Go here for more info.
@googlebot I signed it!
Hey @kevinzakka, I was actually able to apply the linter fixes internally and merge the PR that way. Thanks for the contribution!
This PR implements a continuous version of the environments and tasks, which allows us to generate dense trajectories. Specifically it contains:
ContinuousEnvironment
class which subclasses the baseenvironment.Environment
class and eliminates the "do-it-in-1-step"PickPlace
andpush
primitives.continuous
kwarg to each instance ofTask
which should be toggled when usingContinuousEnvironment
.planners.PickPlacePlanner
for pick-and-place tasks andplanners.PushPlanner
for pushing tasks to generate intermediate actions given the pick and place poses generated by the discrete version of the oracle. The basePlanner
class is implemented via splines.Here is some example code to illustrate the new API, which closely mimics the discrete one:
This generates the following trajectory for the
StackBlockPyramid
task:https://user-images.githubusercontent.com/10518920/124039895-ac213780-d9b8-11eb-91a2-97577074bbe7.mp4
You can also increase the density of the steps generated by the oracle, which allows you to generate more intermediate observations. Here is a second demonstration generated via
agent = task.oracle(env, steps_per_seg=5)
:https://user-images.githubusercontent.com/10518920/124040871-9ad92a80-d9ba-11eb-9c6b-524be81f5e56.mp4