Skip to content

Commit

Permalink
fixed typo
Browse files Browse the repository at this point in the history
  • Loading branch information
ZealousGinger committed Jul 3, 2024
1 parent bcc3274 commit 948676a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions linorobot2_gazebo/scripts/map2gazebo.py
Original file line number Diff line number Diff line change
Expand Up @@ -252,11 +252,11 @@ def __init__(self, map_dir, export_dir, world_dir, height=1.0):
def map_callback(self):
all_maps = self._extract_maps(self.map_dir)
for key, value in all_maps.items():
pgm_dir = value[0] if ".pgm" in value[0] or ".png" in value[0] else value[1]
map_file_dir = value[0] if ".pgm" in value[0] or ".png" in value[0] else value[1]
info_dir = value[0] if ".yaml" in value[0] else value[1]
map_array = cv2.imread(pgm_dir)
map_array = cv2.imread(map_file_dir)
map_array = cv2.flip(map_array, 0)
print(f'loading map file: {pgm_dir}')
print(f'loading map file: {map_file_dir}')
try:
map_array = cv2.cvtColor(map_array, cv2.COLOR_BGR2GRAY)
except cv2.error as err:
Expand Down

0 comments on commit 948676a

Please sign in to comment.