1 Star 0 Fork 0

爱折腾智能机器人/act-plus-plus

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
align.py 1.30 KB
一键复制 编辑 原始数据 按行查看 历史
from interbotix_xs_modules.arm import InterbotixManipulatorXS
from aloha_scripts.robot_utils import move_arms, torque_on, move_grippers
from constants import PUPPET_GRIPPER_JOINT_OPEN, PUPPET_GRIPPER_JOINT_CLOSE
import argparse
import numpy as np
# for calibrating head cam and arms being symmetrical
def main():
argparser = argparse.ArgumentParser()
argparser.add_argument('--all', action='store_true', default=False)
args = argparser.parse_args()
puppet_bot_left = InterbotixManipulatorXS(robot_model="vx300s", group_name="arm", gripper_name="gripper", robot_name=f'puppet_left', init_node=True)
puppet_bot_right = InterbotixManipulatorXS(robot_model="vx300s", group_name="arm", gripper_name="gripper", robot_name=f'puppet_right', init_node=False)
all_bots = [puppet_bot_left, puppet_bot_right]
for bot in all_bots:
torque_on(bot)
multiplier = np.array([-1, 1, 1, -1, 1, 1])
puppet_sleep_position_left = np.array([-0.8, -0.5, 0.5, 0, 0.65, 0])
puppet_sleep_position_right = puppet_sleep_position_left * multiplier
all_positions = [puppet_sleep_position_left, puppet_sleep_position_right]
move_arms(all_bots, all_positions, move_time=2)
# move_grippers(all_bots, [PUPPET_GRIPPER_JOINT_OPEN] * 2, move_time=1) # open
if __name__ == '__main__':
main()
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/ncnynl/act-plus-plus.git
git@gitee.com:ncnynl/act-plus-plus.git
ncnynl
act-plus-plus
act-plus-plus
main

搜索帮助