Skip to content

Commit

Permalink
[elevator_move_base_pr2] Use list() for python3 compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
tkmtnt7000 authored and mqcmd196 committed Dec 7, 2023
1 parent f2e6dd6 commit 9c780d1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions elevator_move_base_pr2/node_scripts/match_template.py
Original file line number Diff line number Diff line change
Expand Up @@ -108,15 +108,15 @@ def image_cb(self, msg):

# publish result
msg = StringStamped(header=msg.header)
msg.data = ' '.join([n for n, r in results.items() if r.found])
msg.data = ' '.join([n for n, r in list(results.items()) if r.found])
rospy.loginfo('Matched template: {}'.format(msg.data))
self.pub_result.publish(msg)

# publish debug image
self.publish_debug(img, results)

def publish_debug(self, img, results):
templates = self.templates.values()
templates = list(self.templates.values())
templates.sort(key=lambda t: t.name)
imgs = [t.image for t in templates]

Expand Down

0 comments on commit 9c780d1

Please sign in to comment.