mirror of
https://github.com/AtsushiSakai/PythonRobotics.git
synced 2026-04-22 03:00:22 -04:00
fix error: 'numpy.ndarray' object has no attribute 'append' (#662)
* Update grid_map_lib.py fix error: 'numpy.ndarray' object has no attribute 'append' * Update test_grid_map_lib.py * Update test_grid_map_lib.py Co-authored-by: Atsushi Sakai <asakai.amsl+github@gmail.com>
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
from Mapping.grid_map_lib.grid_map_lib import GridMap
|
||||
import numpy as np
|
||||
|
||||
|
||||
def test_position_set():
|
||||
@@ -19,6 +20,8 @@ def test_polygon_set():
|
||||
grid_map = GridMap(600, 290, 0.7, 60.0, 30.5)
|
||||
|
||||
grid_map.set_value_from_polygon(ox, oy, 1.0, inside=False)
|
||||
grid_map.set_value_from_polygon(np.array(ox), np.array(oy),
|
||||
1.0, inside=False)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
Reference in New Issue
Block a user