Skip to content

Commit 574ee8e

Browse files
committed
add non-tiled
1 parent 00f0b01 commit 574ee8e

File tree

2 files changed

+27
-3
lines changed

2 files changed

+27
-3
lines changed

source/extensions/omni.isaac.lab_tasks/omni/isaac/lab_tasks/direct/cartpole/cartpole_camera_env.py

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
from omni.isaac.lab.assets import Articulation, ArticulationCfg
1818
from omni.isaac.lab.envs import DirectRLEnv, DirectRLEnvCfg, ViewerCfg
1919
from omni.isaac.lab.scene import InteractiveSceneCfg
20-
from omni.isaac.lab.sensors import TiledCamera, TiledCameraCfg, save_images_to_file
20+
from omni.isaac.lab.sensors import Camera, CameraCfg, TiledCamera, TiledCameraCfg, save_images_to_file
2121
from omni.isaac.lab.sensors.camera.tiled_camera import TiledCameraOld
2222
from omni.isaac.lab.sim import SimulationCfg
2323
from omni.isaac.lab.utils import configclass
@@ -54,6 +54,17 @@ class CartpoleRGBCameraEnvCfg(DirectRLEnvCfg):
5454
width=128,
5555
height=128,
5656
)
57+
# tiled_camera: CameraCfg = CameraCfg(
58+
# class_type=Camera,
59+
# prim_path="/World/envs/env_.*/Camera",
60+
# offset=CameraCfg.OffsetCfg(pos=(-5.0, 0.0, 2.0), rot=(1.0, 0.0, 0.0, 0.0), convention="world"),
61+
# data_types=["rgb"],
62+
# spawn=sim_utils.PinholeCameraCfg(
63+
# focal_length=24.0, focus_distance=400.0, horizontal_aperture=20.955, clipping_range=(0.1, 20.0)
64+
# ),
65+
# width=128,
66+
# height=128,
67+
# )
5768
num_observations = num_channels * tiled_camera.height * tiled_camera.width
5869
write_image_to_file = False
5970

source/extensions/omni.isaac.lab_tasks/omni/isaac/lab_tasks/direct/shadow_hand/shadow_hand_camera_env.py

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
import omni.isaac.lab.sim as sim_utils
1515
from omni.isaac.lab.assets import Articulation, RigidObject
1616
from omni.isaac.lab.scene import InteractiveSceneCfg
17-
from omni.isaac.lab.sensors import TiledCamera, TiledCameraCfg, save_images_to_file
17+
from omni.isaac.lab.sensors import Camera, CameraCfg, TiledCamera, TiledCameraCfg, save_images_to_file
1818
from omni.isaac.lab.sensors.camera.tiled_camera import TiledCameraOld
1919
from omni.isaac.lab.sim import PhysxCfg, SimulationCfg
2020
from omni.isaac.lab.sim.spawners.materials.physics_materials_cfg import RigidBodyMaterialCfg
@@ -28,7 +28,7 @@
2828
@configclass
2929
class ShadowHandRGBCameraEnvCfg(ShadowHandEnvCfg):
3030
# scene
31-
scene: InteractiveSceneCfg = InteractiveSceneCfg(num_envs=64, env_spacing=5.0, replicate_physics=True)
31+
scene: InteractiveSceneCfg = InteractiveSceneCfg(num_envs=128, env_spacing=5.0, replicate_physics=True)
3232

3333
# camera
3434
tiled_camera: TiledCameraCfg = TiledCameraCfg(
@@ -43,6 +43,19 @@ class ShadowHandRGBCameraEnvCfg(ShadowHandEnvCfg):
4343
width=320,
4444
height=240,
4545
)
46+
# tiled_camera: CameraCfg = CameraCfg(
47+
# prim_path="/World/envs/env_.*/Camera",
48+
# offset=TiledCameraCfg.OffsetCfg(pos=(0.0, -0.27, 1.5), rot=(0.0, 0.0, 0.0, -1.0), convention="opengl"),
49+
# # offset=TiledCameraCfg.OffsetCfg(pos=(-2.0, 0.0, 0.75), rot=(-0.5, -0.5, 0.5, 0.5), convention="opengl"),
50+
# data_types=["rgb"],
51+
# # class_type=TiledCameraOld,
52+
# spawn=sim_utils.PinholeCameraCfg(
53+
# focal_length=24.0, focus_distance=400.0, horizontal_aperture=20.955, clipping_range=(0.1, 20.0)
54+
# ),
55+
# width=320,
56+
# height=240,
57+
# )
58+
4659
write_image_to_file = False
4760

4861
# env

0 commit comments

Comments
 (0)