Skip to content

Commit c03fd1d

Browse files
committed
reorganized folder structure and changed package name
1 parent e3fdc28 commit c03fd1d

File tree

10 files changed

+14
-12
lines changed

10 files changed

+14
-12
lines changed

pyproject.toml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ requires = ["setuptools>=42", "wheel"]
33
build-backend = "setuptools.build_meta"
44

55
[project]
6-
name = "teleop_demo_mujoco"
6+
name = "teleop_demo_python"
77
version = "0.1.0"
88
description = "Teleoperation demo with MuJoCo and UR5 robot"
99
readme = "README.md"
@@ -17,6 +17,8 @@ dependencies = [
1717
"numpy",
1818
"meshcat",
1919
"placo",
20+
"ur_rtde",
21+
"dynamixel-sdk",
2022
]
2123

2224
[project.optional-dependencies]
@@ -28,10 +30,10 @@ dev = [
2830
]
2931

3032
[tool.setuptools]
31-
packages = ["teleop_demo_mujoco"]
33+
packages = ["teleop_demo_python"]
3234

3335
[tool.setuptools.package-data]
34-
teleop_demo_mujoco = ["../assets/**/*"]
36+
teleop_demo_python = ["../assets/**/*"]
3537

3638
[tool.black]
3739
line-length = 88

scripts/ur5e_dual_arm_demo.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
import os
2-
from teleop_demo_mujoco.mujoco_teleop_controller import (
2+
from teleop_demo_python.mujoco_teleop_controller import (
33
MujocoTeleopController,
44
)
5-
from teleop_demo_mujoco.path_utils import ASSET_PATH
5+
from teleop_demo_python.utils.path_utils import ASSET_PATH
66

77

88
def main():

setup.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,4 +44,4 @@ python setup.py install || { echo "Failed to install RoboticsService-Python"; ex
4444

4545
cd ../..
4646

47-
pip install -e . || { echo "Failed to install teleop_demo_mujoco with pip"; exit 1; }
47+
pip install -e . || { echo "Failed to install teleop_demo_python with pip"; exit 1; }

setup_conda.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -125,10 +125,10 @@ elif [[ "$1" == "--install" ]]; then
125125

126126
cd ..
127127

128-
pip install -e . || { echo "Failed to install teleop_demo_mujoco with pip"; exit 1; }
128+
pip install -e . || { echo "Failed to install teleop_demo_python with pip"; exit 1; }
129129

130130
echo -e "\n"
131-
echo -e "[INFO] teleop_demo_mujoco is installed in conda environment '$ENV_NAME'.\n"
131+
echo -e "[INFO] teleop_demo_python is installed in conda environment '$ENV_NAME'.\n"
132132
echo -e "\n"
133133
else
134134
echo "Invalid argument. Use --conda to create a conda environment or --install to install the package."

teleop_demo_mujoco/mujoco_teleop_controller.py renamed to teleop_demo_python/mujoco_teleop_controller.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,13 @@
1313
frame_viz,
1414
)
1515

16-
from teleop_demo_mujoco.geometry import (
16+
from teleop_demo_python.utils.geometry import (
1717
R_HEADSET_TO_WORLD,
1818
apply_delta_pose,
1919
quat_diff_as_angle_axis,
2020
)
2121

22-
from teleop_demo_mujoco.pico_client import PicoClient
22+
from teleop_demo_python.utils.pico_client import PicoClient
2323

2424

2525
class MujocoTeleopController:
@@ -281,7 +281,7 @@ def _process_xr_pose(self, xr_pose, src_name):
281281
R_transform = np.eye(4)
282282
R_transform[:3, :3] = self.R_headset_world
283283
R_quat = tf.quaternion_from_matrix(R_transform)
284-
controller_quat = tf.quaternion_multiply(R_quat, controller_quat)
284+
controller_quat = tf.quaternion_multiply(tf.quaternion_multiply(R_quat, controller_quat), tf.quaternion_conjugate(R_quat))
285285

286286
if self.init_controller_xyz[src_name] is None:
287287
# First time processing the pose

teleop_demo_python/utils/__init__.py

Whitespace-only changes.
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
import os
22

33
PACKAGE_PATH = os.path.dirname(os.path.abspath(__file__))
4-
ASSET_PATH = os.path.join(PACKAGE_PATH, "../assets")
4+
ASSET_PATH = os.path.join(PACKAGE_PATH, "../../assets")

0 commit comments

Comments
 (0)