Implementation:ARISE Initiative Robosuite PickPlace Environment
| Knowledge Sources | |
|---|---|
| Domains | Robotics, Simulation, Manipulation |
| Last Updated | 2026-02-15 07:00 GMT |
Overview
Concrete tool for simulating a pick-and-place bin sorting manipulation task provided by robosuite.
Description
The PickPlace class implements a single-arm robot pick-and-place task where objects must be sorted from a source bin into their correct target compartments in a destination bin. The environment features four everyday objects -- Milk, Bread, Cereal, and Can -- which are initially placed in a source bin (bin1) and must be moved to their designated compartments in a target bin (bin2). Visual indicator objects are placed in the target bin to show where each object belongs.
The reward function supports both sparse and dense modes. In sparse mode, a discrete reward of 1.0 is given per object correctly placed in its bin. In dense (shaped) mode, four staged components are computed: reaching (in [0, 0.1], proportional to distance to closest active object), grasping (in {0, 0.35}, binary for contact with any active object), lifting (in {0, [0.35, 0.5]}, proportional to lifting height above the target bin), and hovering (in {0, [0.5, 0.7]}, proportional to distance from object to its target bin position). Successfully placed objects always contribute 1.0. The final reward is normalized by reward_scale / 4.0 (or reward_scale / 1.0 for single object mode).
The environment supports three task modes via single_object_mode: mode 0 uses all four objects (full task), mode 1 randomly selects one object type per reset, and mode 2 fixes the object type. Convenience subclasses PickPlaceSingle, PickPlaceMilk, PickPlaceBread, PickPlaceCereal, and PickPlaceCan are provided. Success requires all active objects to be in their correct bins while the gripper is not in close proximity.
Usage
Use this environment for training and evaluating pick-and-place sorting policies. The multi-object variant tests generalization across object shapes and sizes, while single-object variants are suitable for curriculum learning approaches.
Code Reference
Source Location
- Repository: ARISE_Initiative_Robosuite
- File: robosuite/environments/manipulation/pick_place.py
- Lines: 1-848
Signature
class PickPlace(ManipulationEnv):
def __init__(
self,
robots,
env_configuration="default",
controller_configs=None,
gripper_types="default",
base_types="default",
initialization_noise="default",
table_full_size=(0.39, 0.49, 0.82),
table_friction=(1, 0.005, 0.0001),
bin1_pos=(0.1, -0.25, 0.8),
bin2_pos=(0.1, 0.28, 0.8),
z_offset=0.0,
z_rotation=None,
use_camera_obs=True,
use_object_obs=True,
reward_scale=1.0,
reward_shaping=False,
single_object_mode=0,
object_type=None,
has_renderer=False,
has_offscreen_renderer=True,
render_camera="frontview",
render_collision_mesh=False,
render_visual_mesh=True,
render_gpu_device_id=-1,
control_freq=20,
lite_physics=True,
horizon=1000,
ignore_done=False,
hard_reset=True,
camera_names="agentview",
camera_heights=256,
camera_widths=256,
camera_depths=False,
camera_segmentations=None,
renderer="mjviewer",
renderer_config=None,
seed=None,
):
Import
from robosuite.environments.manipulation.pick_place import PickPlace
# Convenience variants:
from robosuite.environments.manipulation.pick_place import PickPlaceSingle
from robosuite.environments.manipulation.pick_place import PickPlaceMilk
from robosuite.environments.manipulation.pick_place import PickPlaceBread
from robosuite.environments.manipulation.pick_place import PickPlaceCereal
from robosuite.environments.manipulation.pick_place import PickPlaceCan
I/O Contract
Inputs
| Name | Type | Required | Description |
|---|---|---|---|
| robots | str or list of str | Yes | Specification for a single single-arm robot (e.g., "Panda") |
| single_object_mode | int | No | 0 = all objects, 1 = random single object per reset, 2 = fixed single object. Default: 0 |
| object_type | str | No | "milk", "bread", "cereal", or "can"; only used when single_object_mode=2. Default: None |
| bin1_pos | 3-tuple | No | Absolute cartesian coordinates of the source bin. Default: (0.1, -0.25, 0.8) |
| bin2_pos | 3-tuple | No | Absolute cartesian coordinates of the target bin. Default: (0.1, 0.28, 0.8) |
| z_offset | float | No | Z-axis offset for initializing objects in bin. Default: 0.0 |
| z_rotation | float, tuple, or None | No | Controls range of z-rotation initialization for objects. Default: None |
| reward_scale | None or float | No | Scales the normalized reward. Default: 1.0 |
| reward_shaping | bool | No | If True, uses dense staged rewards. Default: False |
| horizon | int | No | Episode length in timesteps. Default: 1000 |
Outputs
| Name | Type | Description |
|---|---|---|
| {ObjName}_pos | np.array (3,) | 3D position of each object body |
| {ObjName}_quat | np.array (4,) | Quaternion orientation (xyzw) of each object |
| {ObjName}_to_{prefix}eef_pos | np.array (3,) | Relative position from object to end-effector |
| {ObjName}_to_{prefix}eef_quat | np.array (4,) | Relative orientation from object to end-effector |
| obj_id | int | Active object ID (only in single_object_mode=1) |
| reward | float | Scalar reward value per step |
Usage Examples
import robosuite as suite
import numpy as np
# Create a PickPlace environment with all four objects
env = suite.make(
env_name="PickPlace",
robots="Panda",
has_renderer=False,
has_offscreen_renderer=False,
use_camera_obs=False,
use_object_obs=True,
reward_shaping=True,
horizon=1000,
)
obs = env.reset()
for i in range(1000):
action = np.random.randn(env.action_dim)
obs, reward, done, info = env.step(action)
if done:
break
env.close()
# Use the single-can variant for easier training
env_can = suite.make(
env_name="PickPlaceCan",
robots="Sawyer",
has_renderer=False,
has_offscreen_renderer=False,
use_camera_obs=False,
)