From 75dce61d35dc2248aa06502558ed1638ca02df80 Mon Sep 17 00:00:00 2001 From: Kevin Lin Date: Fri, 29 Aug 2025 17:50:12 -0700 Subject: [PATCH 1/2] add floating legged base w vertical py and xml --- .../floating_legged_base_with_vertical.xml | 23 ++++++++++++++ .../floating_legged_base_with_vertical.py | 30 +++++++++++++++++++ 2 files changed, 53 insertions(+) create mode 100644 robosuite/models/assets/bases/floating_legged_base_with_vertical.xml create mode 100644 robosuite/models/bases/floating_legged_base_with_vertical.py diff --git a/robosuite/models/assets/bases/floating_legged_base_with_vertical.xml b/robosuite/models/assets/bases/floating_legged_base_with_vertical.xml new file mode 100644 index 0000000000..204671f4d6 --- /dev/null +++ b/robosuite/models/assets/bases/floating_legged_base_with_vertical.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/robosuite/models/bases/floating_legged_base_with_vertical.py b/robosuite/models/bases/floating_legged_base_with_vertical.py new file mode 100644 index 0000000000..0327ec158b --- /dev/null +++ b/robosuite/models/bases/floating_legged_base_with_vertical.py @@ -0,0 +1,30 @@ +""" +Rethink's Generic Mount (Officially used on Sawyer). +""" + +import numpy as np + +from robosuite.models.bases.mobile_base_model import MobileBaseModel +from robosuite.utils.mjcf_utils import xml_path_completion + + +class FloatingLeggedBaseWithVertical(MobileBaseModel): + """ + Dummy mobile base to signify no mount. + + Args: + idn (int or str): Number or some other unique identification string for this mount instance + """ + + def __init__(self, idn=0): + super().__init__( + xml_path_completion("bases/floating_legged_base_with_vertical.xml"), idn=idn + ) + + @property + def top_offset(self): + return np.array((0, 0, 0)) + + @property + def horizontal_radius(self): + return 0 From d1b6ffa86ffa3cd926ad328095221f1752d55087 Mon Sep 17 00:00:00 2001 From: Kevin Lin Date: Fri, 29 Aug 2025 17:51:49 -0700 Subject: [PATCH 2/2] Add vertical legged base to init --- robosuite/models/bases/__init__.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/robosuite/models/bases/__init__.py b/robosuite/models/bases/__init__.py index 4b19278a27..d5e8618ef5 100644 --- a/robosuite/models/bases/__init__.py +++ b/robosuite/models/bases/__init__.py @@ -13,6 +13,7 @@ from .null_mobile_base import NullMobileBase from .no_actuation_base import NoActuationBase from .floating_legged_base import FloatingLeggedBase +from .floating_legged_base_with_vertical import FloatingLeggedBaseWithVertical from .null_base import NullBase from .spot_base import Spot, SpotFloating @@ -24,6 +25,7 @@ "NullMobileBase": NullMobileBase, "NoActuationBase": NoActuationBase, "FloatingLeggedBase": FloatingLeggedBase, + "FloatingLeggedBaseWithVertical": FloatingLeggedBaseWithVertical, "Spot": Spot, "SpotFloating": SpotFloating, "NullBase": NullBase,