Skip to content

Commit 01c6ca5

Browse files
committed
implemented getter methods for dimension, distance and point array
1 parent 1db6f84 commit 01c6ca5

File tree

1 file changed

+25
-0
lines changed

1 file changed

+25
-0
lines changed

doc/3_sensor_models/3_2_lidar.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -197,4 +197,29 @@ class ScanPoint:
197197
self.point_array = XYArray(np.array([[x_m], [y_m]]))
198198
self.transformed_x = None
199199
self.transformed_y = None
200+
```
201+
202+
Then, some member methods for accessing or visualizing the data. The getter methods for a dimension of x-y array, distance and x-y array of point are implemented as follow.
203+
```python
204+
def get_dimension(self):
205+
"""
206+
Return point's x-y array data's dimension value
207+
"""
208+
209+
return self.point_array.get_dimension()
210+
211+
def get_distance_m(self):
212+
"""
213+
Return point's distance data[m]
214+
"""
215+
216+
return self.distance_m
217+
218+
def get_point_array(self):
219+
"""
220+
Return point's x-y array data
221+
Type is ndarray object
222+
"""
223+
224+
return self.point_array.get_data()
200225
```

0 commit comments

Comments
 (0)