Incompatible device of velocity tensor in function getVelocities: expected device 0, received device -1 (original) (raw)
Hi all!
My team and I are working on a Capstone project and we’re trying to get an IMU sensor to work on a self-balancing two-wheeled robot all through Python, but we keep getting the following error:
Incompatible device of velocity tensor in function getVelocities: expected device 0, received device -1
We tried creating the sensor through the Python class and adding it to the World’s scene property, creating through kit commands, creating with or without initialization…
We’ve searched high and low for a solution (or even the origin of the issue), but to no avail. Weird thing is, the IMU sensor still works and gives back valid data, but the console is filled with those errors.
Any help would be greatly appreciated!
whoishoa August 12, 2024, 2:53am 2
We have the exact same problem.
Did you solve this problem?
I try to load the jackal mobile robot(using USD file in isaac sim) with isaac lab.
It is fine to load the robot, but the error message shows 2025-01-17 02:37:19 [14,152ms] [Error] [omni.physx.tensors.plugin] Incompatible device of velocity tensor in function getVelocities: expected device 0, received device -1
I am also having the same problem unfortunately. Were any of you able to find a fix?
PeterNV November 3, 2025, 7:36pm 8
Please share your sample reproduce script if you still have the issue.
### Description
When using the Jackal USD asset in IsaacLab for robotics simulation, I consistently encounter a device incompatibility error related to PhysX tensors, which may affect the training process.
Steps to Reproduce
- Integrate the Jackal USD asset into an IsaacLab simulation workflow.
- Initiate the simulation.
- Observe the error logs related to `omni.physx.tensors.plugin` as shown below.
Environment
- IsaacLab Version: 0.36.2
- Python Version: 3.10
- OS: Windows 11
- GPU: RTX 3070ti
Logs/Error Messages
```
2025-11-04 12:12:37 [93,027ms] [Error] [omni.physx.tensors.plugin] Incompatible device of velocity tensor in function omni::physx::tensors::GpuRigidBodyView::getVelocities: expected device 0, received device -1
2025-11-04 12:12:37 [93,039ms] [Error] [omni.physx.tensors.plugin] Incompatible device of velocity tensor in function omni::physx::tensors::GpuRigidBodyView::getVelocities: expected device 0, received device -1
… (repeat of similar errors)
```
Expected Behavior
The simulation should run without PhysX device incompatibility errors, and the Jackal robot should behave as intended in the simulation.
Actual Behavior
Persistent `Incompatible device of velocity tensor` errors are thrown
PeterNV November 4, 2025, 10:54pm 10
Where’s the Jackal USD asset? And how did you use it in your simulation? Please attach the script if you can repro it.
Thank you for your response! I am currently in the process of developing a manager-based environment, and the configuration of this environment is as follows:
@configclass
class JackalSceneCfg(InteractiveSceneCfg):
"""Configuration for the flat terrain scene with a Jackal robot."""
ground = AssetBaseCfg(
prim_path="/World/Ground",
spawn=sim_utils.GroundPlaneCfg(size=(1000.0, 1000.0)),
)
# robot: Jackal articulation
robot = ArticulationCfg(
prim_path="{ENV_REGEX_NS}/Robot",
spawn=sim_utils.UsdFileCfg(
usd_path=f"{ISAAC_NUCLEUS_DIR}/Robots/Clearpath/Jackal/jackal.usd",
activate_contact_sensors=True,
# rigid_props=sim_utils.RigidBodyPropertiesCfg(
# rigid_body_enabled=True,
# kinematic_enabled=False,
# disable_gravity=False,
# max_depenetration_velocity=10.0,
# ),
# collision_props=sim_utils.CollisionPropertiesCfg(
# collision_enabled=True,
# ),
# articulation_props=sim_utils.ArticulationRootPropertiesCfg(
# enabled_self_collisions=False,
# ),
),
init_state=ArticulationCfg.InitialStateCfg(
pos=(0.0, 0.0, 0.1),
rot=(1.0, 0.0, 0.0, 0.0), # w, x, y, z format
joint_pos={".*": 0.0},
joint_vel={".*": 0.0},
),
actuators={
"wheels": ImplicitActuatorCfg(
# Correct joint names based on the provided image
joint_names_expr=[
"front_left_wheel_joint", "front_right_wheel_joint",
"rear_left_wheel_joint", "rear_right_wheel_joint"
],
stiffness=100.0, # Approximate Kp from task.py
damping=100.0 # Approximate Kd from task.py
)
}
)
#other assets
...
#some managers
...
#env cfg
@configclass
class NavigationEnvCfg(ManagerBasedRLEnvCfg):
"""Configuration for the navigation environment."""
# environment settings
scene: JackalSceneCfg = JackalSceneCfg(num_envs=128, env_spacing=10)
actions: ActionsCfg = ActionsCfg()
observations: ObservationsCfg = ObservationsCfg()
events: EventCfg = EventCfg()
# mdp settings
commands: CommandsCfg = CommandsCfg()
rewards: RewardsCfg = RewardsCfg()
terminations: TerminationsCfg = TerminationsCfg()
def __post_init__(self):
"""Post initialization."""
self.viewer.eye = (20.0, 20.0, 20.0)
# general settings
self.decimation = 4
self.episode_length_s = 100.0
# simulation settings
self.sim.dt = 0.005
self.sim.render_interval = self.decimation
self.scene.env_spacing = WALL_LENGTH + 2
self.scene.replicate_physics = False
if self.scene.contact_forces is not None:
self.scene.contact_forces.update_period = self.sim.dt
And I use my environment through the gym interface:
class IsaacLabEnv:
"""Wrapper for IsaacLab environments to be compatible with MuJoCo Playground"""
def __init__(
self,
task_name: str,
device: str,
num_envs: int,
seed: int,
action_bounds: Optional[float] = None,
render_mode: Optional[str] = None,
headless: bool = True,
):
from isaaclab.app import AppLauncher
app_launcher = AppLauncher(headless=headless, device=device)
simulation_app = app_launcher.app
import isaaclab_tasks
from isaaclab_tasks.utils.parse_cfg import parse_env_cfg
env_cfg = parse_env_cfg(
task_name,
device=device,
num_envs=num_envs,
)
env_cfg.seed = seed
self.seed = seed
self.render_mode = render_mode
self.envs = gym.make(task_name, cfg=env_cfg, render_mode=render_mode)
self.num_envs = self.envs.unwrapped.num_envs
self.max_episode_steps = self.envs.unwrapped.max_episode_length
self.action_bounds = action_bounds
self.num_obs = self.envs.unwrapped.single_observation_space["policy"].shape[0]
self.asymmetric_obs = "critic" in self.envs.unwrapped.single_observation_space
if self.asymmetric_obs:
self.num_privileged_obs = self.envs.unwrapped.single_observation_space[
"critic"
].shape[0]
else:
self.num_privileged_obs = 0
self.num_actions = self.envs.unwrapped.single_action_space.shape[0]
Finally, I use following command to run training:
python train_isaac_lab.py --env_name Isaac-Navigation-Flat-Jackal-v0 --num_envs 8 ...
Isaac-Navigation-Flat-Jackal-v0 is the environment that I develop, and then
[Error] [omni.physx.tensors.plugin] Incompatible device of velocity tensor in function omni::physx::tensors::GpuRigidBodyView::getVelocities: expected device 0, received device -1
repeated.
I found some issues about Imu sensor, but still dont know how I can fix it
After deleting the Imu sensor from the Jackal asset, I encountered no error messages. Not sure if it is a good solution.
PeterNV November 5, 2025, 6:15pm 13
If you’re not using the IMU sensor, you can delete it. If you use it, please make sure your operations on IMU is using the same device as your Env.