diff --git a/.gitmodules b/.gitmodules index a9822ef..7c1d312 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,4 +1,4 @@ [submodule "assets"] path = assets url = https://github.com/dexsuite/dex-urdf.git - branch = init_dev + branch = main diff --git a/assets b/assets index 0eccff9..e5ef022 160000 --- a/assets +++ b/assets @@ -1 +1 @@ -Subproject commit 0eccff98d4286d3f7602400efae92e22275ed8bf +Subproject commit e5ef022c412461e2faa23e490dd3b5af933b0a5c diff --git a/example/position_retargeting/visualize_hand_object.py b/example/position_retargeting/visualize_hand_object.py index d8ebba9..464a249 100644 --- a/example/position_retargeting/visualize_hand_object.py +++ b/example/position_retargeting/visualize_hand_object.py @@ -29,7 +29,7 @@ def viz_hand_object(robots: Optional[Tuple[RobotName]], data_root: Path, fps: in def main(dexycb_dir: str, robots: Optional[List[RobotName]] = None, fps: int = 5): print(robots) data_root = Path(dexycb_dir).absolute() - robot_dir = Path(__file__).parent.parent.parent / "assets" / "robots" + robot_dir = Path(__file__).absolute().parent.parent.parent / "assets" / "robots" / "hands" RetargetingConfig.set_default_urdf_dir(robot_dir) if not data_root.exists(): raise ValueError(f"Path to DexYCB dir: {data_root} does not exist.") diff --git a/example/vector_retargeting/detect_from_video.py b/example/vector_retargeting/detect_from_video.py index f7c81ab..f614402 100644 --- a/example/vector_retargeting/detect_from_video.py +++ b/example/vector_retargeting/detect_from_video.py @@ -76,7 +76,7 @@ def main( """ config_path = get_default_config_path(robot_name, retargeting_type, hand_type) - robot_dir = Path(__file__).parent.parent.parent / "assets" / "robots" + robot_dir = Path(__file__).absolute().parent.parent.parent / "assets" / "robots" / "hands" RetargetingConfig.set_default_urdf_dir(str(robot_dir)) retargeting = RetargetingConfig.load_from_file(config_path).build() retarget_video(retargeting, video_path, output_path, str(config_path)) diff --git a/example/vector_retargeting/render_robot_hand.py b/example/vector_retargeting/render_robot_hand.py index 048e20b..e065f3f 100644 --- a/example/vector_retargeting/render_robot_hand.py +++ b/example/vector_retargeting/render_robot_hand.py @@ -124,7 +124,7 @@ def main( By default, it is set to None, implying no video will be saved. headless: Set to visualize the rendering on the screen by opening the viewer window. """ - robot_dir = Path(__file__).parent.parent.parent / "assets" / "robots" + robot_dir = Path(__file__).absolute().parent.parent.parent / "assets" / "robots" / "hands" RetargetingConfig.set_default_urdf_dir(str(robot_dir)) supported_renderer = ["sapien", "sim_web_visualizer", "trimesh"] diff --git a/tests/test_retargeting_config.py b/tests/test_retargeting_config.py index 8cc8f51..f8bf2ca 100644 --- a/tests/test_retargeting_config.py +++ b/tests/test_retargeting_config.py @@ -26,7 +26,7 @@ class TestRetargetingConfig: config_dir = Path(__file__).parent.parent / "dex_retargeting" / "configs" - robot_dir = Path(__file__).parent.parent / "assets" / "robots" + robot_dir = Path(__file__).parent.parent / "assets" / "robots" / "hands" RetargetingConfig.set_default_urdf_dir(str(robot_dir.absolute())) config_paths = ( diff --git a/tests/test_sapien_optimizer.py b/tests/test_sapien_optimizer.py index b1dafd7..c59e7b7 100644 --- a/tests/test_sapien_optimizer.py +++ b/tests/test_sapien_optimizer.py @@ -13,7 +13,7 @@ class TestSapienOptimizer: np.set_printoptions(precision=4) config_dir = Path(__file__).parent.parent / "dex_retargeting" / "configs" - robot_dir = Path(__file__).parent.parent / "assets" / "robots" + robot_dir = Path(__file__).parent.parent / "assets" / "robots" / "hands" RetargetingConfig.set_default_urdf_dir(str(robot_dir.absolute())) @staticmethod