Skip to content

Commit e142064

Browse files
committed
updated generated stubs
1 parent ad416ea commit e142064

3 files changed

Lines changed: 90 additions & 90 deletions

File tree

python/rcsss/_core/common.pyi

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -11,37 +11,37 @@ import pybind11_stubgen.typing_ext
1111

1212
__all__ = [
1313
"FrankaHandTCPOffset",
14-
"GConfig",
15-
"GState",
1614
"Gripper",
15+
"GripperConfig",
16+
"GripperState",
1717
"IK",
1818
"IdentityRotMatrix",
1919
"IdentityRotQuatVec",
2020
"IdentityTranslation",
2121
"Pose",
22-
"RConfig",
2322
"RPY",
24-
"RState",
2523
"Robot",
24+
"RobotConfig",
25+
"RobotState",
2626
]
2727

28-
class GConfig:
29-
pass
30-
31-
class GState:
32-
pass
33-
3428
class Gripper:
3529
def get_normalized_width(self) -> float: ...
36-
def get_parameters(self) -> GConfig: ...
37-
def get_state(self) -> GState: ...
30+
def get_parameters(self) -> GripperConfig: ...
31+
def get_state(self) -> GripperState: ...
3832
def grasp(self) -> None: ...
3933
def is_grasped(self) -> bool: ...
4034
def open(self) -> None: ...
4135
def reset(self) -> None: ...
4236
def set_normalized_width(self, width: float, force: float = 0) -> None: ...
4337
def shut(self) -> None: ...
4438

39+
class GripperConfig:
40+
pass
41+
42+
class GripperState:
43+
pass
44+
4545
class IK:
4646
def __init__(self, urdf_path: str, max_duration_ms: int = 300) -> None: ...
4747
def ik(
@@ -104,9 +104,6 @@ class Pose:
104104
def translation(self) -> numpy.ndarray[typing.Literal[3], numpy.dtype[numpy.float64]]: ...
105105
def xyzrpy(self) -> numpy.ndarray[typing.Literal[6], numpy.dtype[numpy.float64]]: ...
106106

107-
class RConfig:
108-
pass
109-
110107
class RPY:
111108
pitch: float
112109
roll: float
@@ -126,23 +123,26 @@ class RPY:
126123
self,
127124
) -> numpy.ndarray[tuple[typing.Literal[3], typing.Literal[3]], numpy.dtype[numpy.float64]]: ...
128125

129-
class RState:
130-
pass
131-
132126
class Robot:
133127
def get_base_pose_in_world_coordinates(self) -> Pose: ...
134128
def get_cartesian_position(self) -> Pose: ...
135129
def get_ik(self) -> IK | None: ...
136130
def get_joint_position(self) -> numpy.ndarray[typing.Literal[7], numpy.dtype[numpy.float64]]: ...
137-
def get_parameters(self) -> RConfig: ...
138-
def get_state(self) -> RState: ...
131+
def get_parameters(self) -> RobotConfig: ...
132+
def get_state(self) -> RobotState: ...
139133
def move_home(self) -> None: ...
140134
def reset(self) -> None: ...
141135
def set_cartesian_position(self, pose: Pose) -> None: ...
142136
def set_joint_position(self, q: numpy.ndarray[typing.Literal[7], numpy.dtype[numpy.float64]]) -> None: ...
143137
def to_pose_in_robot_coordinates(self, pose_in_world_coordinates: Pose) -> Pose: ...
144138
def to_pose_in_world_coordinates(self, pose_in_robot_coordinates: Pose) -> Pose: ...
145139

140+
class RobotConfig:
141+
pass
142+
143+
class RobotState:
144+
pass
145+
146146
def FrankaHandTCPOffset() -> numpy.ndarray[tuple[typing.Literal[4], typing.Literal[4]], numpy.dtype[numpy.float64]]: ...
147147
def IdentityRotMatrix() -> numpy.ndarray[tuple[typing.Literal[3], typing.Literal[3]], numpy.dtype[numpy.float64]]: ...
148148
def IdentityRotQuatVec() -> numpy.ndarray[typing.Literal[4], numpy.dtype[numpy.float64]]: ...

python/rcsss/_core/hw/__init__.pyi

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ __all__ = [
2525
"rcs",
2626
]
2727

28-
class FHConfig(rcsss._core.common.GConfig):
28+
class FHConfig(rcsss._core.common.GripperConfig):
2929
async_control: bool
3030
epsilon_inner: float
3131
epsilon_outer: float
@@ -34,7 +34,7 @@ class FHConfig(rcsss._core.common.GConfig):
3434
speed: float
3535
def __init__(self) -> None: ...
3636

37-
class FHState(rcsss._core.common.GState):
37+
class FHState(rcsss._core.common.GripperState):
3838
def __init__(self) -> None: ...
3939
@property
4040
def bool_state(self) -> bool: ...
@@ -80,7 +80,7 @@ class FR3(rcsss._core.common.Robot):
8080
def stop_control_thread(self) -> None: ...
8181
def zero_torque_guiding(self) -> None: ...
8282

83-
class FR3Config(rcsss._core.common.RConfig):
83+
class FR3Config(rcsss._core.common.RobotConfig):
8484
async_control: bool
8585
ik_solver: IKSolver
8686
load_parameters: FR3Load | None
@@ -96,7 +96,7 @@ class FR3Load:
9696
load_mass: float
9797
def __init__(self) -> None: ...
9898

99-
class FR3State(rcsss._core.common.RState):
99+
class FR3State(rcsss._core.common.RobotState):
100100
def __init__(self) -> None: ...
101101

102102
class FrankaHand(rcsss._core.common.Gripper):

python/rcsss/_core/sim.pyi

Lines changed: 66 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,17 @@ import rcsss._core.common
1111

1212
__all__ = [
1313
"CameraType",
14-
"FHConfig",
15-
"FHState",
16-
"FR3",
17-
"FR3Config",
18-
"FR3State",
1914
"FrameSet",
20-
"FrankaHand",
2115
"Sim",
2216
"SimCameraConfig",
2317
"SimCameraSet",
2418
"SimCameraSetConfig",
19+
"SimGripper",
20+
"SimGripperConfig",
21+
"SimGripperState",
22+
"SimRobot",
23+
"SimRobotConfig",
24+
"SimRobotState",
2525
"default_free",
2626
"fixed",
2727
"free",
@@ -65,60 +65,6 @@ class CameraType:
6565
@property
6666
def value(self) -> int: ...
6767

68-
class FHConfig(rcsss._core.common.GConfig):
69-
epsilon_inner: float
70-
epsilon_outer: float
71-
ignored_collision_geoms: list[str]
72-
seconds_between_callbacks: float
73-
def __init__(self) -> None: ...
74-
75-
class FHState(rcsss._core.common.GState):
76-
def __init__(self) -> None: ...
77-
@property
78-
def collision(self) -> bool: ...
79-
@property
80-
def is_moving(self) -> bool: ...
81-
@property
82-
def last_commanded_width(self) -> float: ...
83-
@property
84-
def last_width(self) -> float: ...
85-
@property
86-
def max_unnormalized_width(self) -> float: ...
87-
88-
class FR3(rcsss._core.common.Robot):
89-
def __init__(
90-
self, sim: Sim, id: str, ik: rcsss._core.common.IK, register_convergence_callback: bool = True
91-
) -> None: ...
92-
def get_parameters(self) -> FR3Config: ...
93-
def get_state(self) -> FR3State: ...
94-
def set_joints_hard(self, q: numpy.ndarray[typing.Literal[7], numpy.dtype[numpy.float64]]) -> None: ...
95-
def set_parameters(self, cfg: FR3Config) -> bool: ...
96-
97-
class FR3Config(rcsss._core.common.RConfig):
98-
joint_rotational_tolerance: float
99-
realtime: bool
100-
seconds_between_callbacks: float
101-
tcp_offset: rcsss._core.common.Pose
102-
trajectory_trace: bool
103-
def __init__(self) -> None: ...
104-
105-
class FR3State(rcsss._core.common.RState):
106-
def __init__(self) -> None: ...
107-
@property
108-
def collision(self) -> bool: ...
109-
@property
110-
def ik_success(self) -> bool: ...
111-
@property
112-
def inverse_tcp_offset(self) -> rcsss._core.common.Pose: ...
113-
@property
114-
def is_arrived(self) -> bool: ...
115-
@property
116-
def is_moving(self) -> bool: ...
117-
@property
118-
def previous_angles(self) -> numpy.ndarray[typing.Literal[7], numpy.dtype[numpy.float64]]: ...
119-
@property
120-
def target_angles(self) -> numpy.ndarray[typing.Literal[7], numpy.dtype[numpy.float64]]: ...
121-
12268
class FrameSet:
12369
def __init__(self) -> None: ...
12470
@property
@@ -128,12 +74,6 @@ class FrameSet:
12874
@property
12975
def timestamp(self) -> float: ...
13076

131-
class FrankaHand(rcsss._core.common.Gripper):
132-
def __init__(self, sim: Sim, id: str, cfg: FHConfig) -> None: ...
133-
def get_parameters(self) -> FHConfig: ...
134-
def get_state(self) -> FHState: ...
135-
def set_parameters(self, cfg: FHConfig) -> bool: ...
136-
13777
class Sim:
13878
def __init__(self, mjmdl: int, mjdata: int) -> None: ...
13979
def _start_gui_server(self, id: str) -> None: ...
@@ -172,6 +112,66 @@ class SimCameraSetConfig:
172112
@frame_rate.setter
173113
def frame_rate(self, arg0: int) -> None: ...
174114

115+
class SimGripper(rcsss._core.common.Gripper):
116+
def __init__(self, sim: Sim, id: str, cfg: SimGripperConfig) -> None: ...
117+
def get_parameters(self) -> SimGripperConfig: ...
118+
def get_state(self) -> SimGripperState: ...
119+
def set_parameters(self, cfg: SimGripperConfig) -> bool: ...
120+
121+
class SimGripperConfig(rcsss._core.common.GripperConfig):
122+
epsilon_inner: float
123+
epsilon_outer: float
124+
ignored_collision_geoms: list[str]
125+
seconds_between_callbacks: float
126+
def __init__(self) -> None: ...
127+
128+
class SimGripperState(rcsss._core.common.GripperState):
129+
def __init__(self) -> None: ...
130+
@property
131+
def collision(self) -> bool: ...
132+
@property
133+
def is_moving(self) -> bool: ...
134+
@property
135+
def last_commanded_width(self) -> float: ...
136+
@property
137+
def last_width(self) -> float: ...
138+
@property
139+
def max_unnormalized_width(self) -> float: ...
140+
141+
class SimRobot(rcsss._core.common.Robot):
142+
def __init__(
143+
self, sim: Sim, id: str, ik: rcsss._core.common.IK, register_convergence_callback: bool = True
144+
) -> None: ...
145+
def get_parameters(self) -> SimRobotConfig: ...
146+
def get_state(self) -> SimRobotState: ...
147+
def set_joints_hard(self, q: numpy.ndarray[typing.Literal[7], numpy.dtype[numpy.float64]]) -> None: ...
148+
def set_parameters(self, cfg: SimRobotConfig) -> bool: ...
149+
150+
class SimRobotConfig(rcsss._core.common.RobotConfig):
151+
joint_rotational_tolerance: float
152+
realtime: bool
153+
seconds_between_callbacks: float
154+
tcp_offset: rcsss._core.common.Pose
155+
trajectory_trace: bool
156+
def __init__(self) -> None: ...
157+
158+
class SimRobotState(rcsss._core.common.RobotState):
159+
def __init__(self) -> None: ...
160+
@property
161+
def collision(self) -> bool: ...
162+
@property
163+
def ik_success(self) -> bool: ...
164+
@property
165+
def inverse_tcp_offset(self) -> rcsss._core.common.Pose: ...
166+
@property
167+
def is_arrived(self) -> bool: ...
168+
@property
169+
def is_moving(self) -> bool: ...
170+
@property
171+
def previous_angles(self) -> numpy.ndarray[typing.Literal[7], numpy.dtype[numpy.float64]]: ...
172+
@property
173+
def target_angles(self) -> numpy.ndarray[typing.Literal[7], numpy.dtype[numpy.float64]]: ...
174+
175175
def open_gui_window(uuid: str) -> None: ...
176176

177177
default_free: CameraType # value = <CameraType.default_free: 3>

0 commit comments

Comments
 (0)