@@ -39,18 +39,6 @@ def __str__(self):
39
39
s += "]"
40
40
return s
41
41
42
- def _repr_pretty_ (self , p , cycle ):
43
- """
44
- Pretty string for IPython (superclass method)
45
-
46
- :param p: pretty printer handle (ignored)
47
- :param cycle: pretty printer flag (ignored)
48
-
49
- """
50
- # see https://ipython.org/ipython-doc/stable/api/generated/IPython.lib.pretty.html
51
-
52
- p .text (f"{ i } :\n { str (x )} " )
53
-
54
42
def _ets_world (self , twist : Twist3 ) -> ETS :
55
43
"""
56
44
Convert twist to its corresponding ETS
@@ -201,27 +189,14 @@ def __str__(self):
201
189
return s
202
190
203
191
def __repr__ (self ):
204
- s = "PoERobot([\n "
205
- for j , link in enumerate (self ):
206
- s += repr (link ) + ","
207
- s += "],\n "
192
+ s = "PoERobot([\n "
193
+ s += "\n " .join ([" " + repr (link ) + "," for link in self ])
194
+ s += "\n ],\n "
208
195
s += f" T0=SE3({ np .array_repr (self .T0 .A )} ),\n "
209
- s += f" name={ self .name } ,\n "
196
+ s += f" name=\" { self .name } \" ,\n "
210
197
s += ")"
211
198
return s
212
199
213
- def _repr_pretty_ (self , p , cycle ):
214
- """
215
- Pretty string for IPython (superclass method)
216
-
217
- :param p: pretty printer handle (ignored)
218
- :param cycle: pretty printer flag (ignored)
219
-
<
63E5
/tr>220
- """
221
- # see https://ipython.org/ipython-doc/stable/api/generated/IPython.lib.pretty.html
222
-
223
- p .text (f"{ i } :\n { str (x )} " )
224
-
225
200
def nbranches (self ):
226
201
return 0
227
202
0 commit comments