Skip to content

Commit

Permalink
minor
Browse files Browse the repository at this point in the history
  • Loading branch information
wuphilipp committed Apr 4, 2024
1 parent 7001842 commit 23892c5
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 13 deletions.
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ repos:

# code format according to black
- repo: https://github.com/ambv/black
rev: 23.3.0
rev: 24.2.0
hooks:
- id: black

Expand Down
3 changes: 1 addition & 2 deletions experiments/run_env.py
Original file line number Diff line number Diff line change
Expand Up @@ -106,8 +106,7 @@ def main(args):
if args.agent == "gello":
gello_port = args.gello_port
if gello_port is None:
# usb_ports = glob.glob("/dev/serial/by-id/*")
usb_ports = glob.glob("/dev/cu.usbserial*")
usb_ports = glob.glob("/dev/serial/by-id/*")
print(f"Found {len(usb_ports)} ports")
if len(usb_ports) > 0:
gello_port = usb_ports[0]
Expand Down
2 changes: 1 addition & 1 deletion gello/agents/gello_agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ def make_robot(
gripper_config=(7, 20, -22),
),
# Right UR
"/dev/cu.usbserial-FT7WBG6A": DynamixelRobotConfig(
"/dev/serial/by-id/usb-FTDI_USB__-__Serial_Converter_FT7WBG6A-if00-port0": DynamixelRobotConfig(
joint_ids=(1, 2, 3, 4, 5, 6),
joint_offsets=(
np.pi + 0 * np.pi,
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ pygame
pyspacemouse
PyQt6
pyquaternion
# pyrealsense2
pyrealsense2
pure-python-adb
quaternion
tyro
Expand Down
16 changes: 8 additions & 8 deletions scripts/arm_blocks_play.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,15 @@ class Args:
config = DynamixelRobotConfig(
joint_ids=(1, 2, 3, 4, 5, 6),
joint_offsets=(
np.pi + 0 * np.pi,
2 * np.pi + np.pi / 2,
2 * np.pi + np.pi / 2,
2 * np.pi + np.pi / 2,
1 * np.pi,
3 * np.pi / 2,
-np.pi / 2,
1 * np.pi / 2 + np.pi,
np.pi / 2 + 0 * np.pi,
0 * np.pi + np.pi / 2,
np.pi - 2 * np.pi / 2,
-1 * np.pi / 2 + 2 * np.pi,
),
joint_signs=(1, 1, -1, 1, 1, 1),
gripper_config=(7, 286, 248),
gripper_config=(7, 20, -22),
)


Expand All @@ -40,7 +40,7 @@ def main(args: Args) -> None:
action_space = env.action_spec()
if args.use_gello:
gello = config.make_robot(
port="/dev/cu.usbserial-FT7WBG6A", start_joints=reset_joints_left
port="/dev/cu.usbserial-FT7WBEIA", start_joints=reset_joints_left
)

def policy(timestep) -> np.ndarray:
Expand Down

0 comments on commit 23892c5

Please sign in to comment.