From b8ed1cf6ac0a631305d09d45d3e10f8a755b9978 Mon Sep 17 00:00:00 2001 From: lpaull Date: Tue, 6 Nov 2018 09:02:51 -0500 Subject: [PATCH] fix for lane_filter bug --- Makefile | 11 ----------- .../lane_filter/src/lane_filter_node.py | 12 +++++++----- 2 files changed, 7 insertions(+), 16 deletions(-) diff --git a/Makefile b/Makefile index 29542dc1f2..efb5ea9cbd 100644 --- a/Makefile +++ b/Makefile @@ -32,14 +32,3 @@ include Makefiles/Makefile.demos2017.mk include Makefiles/Makefile.megacity.mk -# For Docker - -branch=$(shell git rev-parse --abbrev-ref HEAD) - -name=duckietown/rpi-duckiebot-base:$(branch) - -main-docker-build: - docker build -t $(name) . - -main-docker-push: - docker push $(name) diff --git a/catkin_ws/src/10-lane-control/lane_filter/src/lane_filter_node.py b/catkin_ws/src/10-lane-control/lane_filter/src/lane_filter_node.py index c33669549f..efda9fb2a3 100755 --- a/catkin_ws/src/10-lane-control/lane_filter/src/lane_filter_node.py +++ b/catkin_ws/src/10-lane-control/lane_filter/src/lane_filter_node.py @@ -139,11 +139,6 @@ def processSegments(self,segment_list_msg): self.pub_belief_img.publish(belief_img) - def getDistributionImage(self, mat, stamp): - bridge = CvBridge() - img = bridge.cv2_to_imgmsg((255 * mat).astype('uint8'), "mono8") - img.header.stamp = stamp - return img # Latency of Estimation including curvature estimation estimation_latency_stamp = rospy.Time.now() - timestamp_now @@ -165,6 +160,13 @@ def getDistributionImage(self, mat, stamp): in_lane_msg.data = True #TODO change with in_lane self.pub_in_lane.publish(in_lane_msg) + def getDistributionImage(self, mat, stamp): + bridge = CvBridge() + img = bridge.cv2_to_imgmsg((255 * mat).astype('uint8'), "mono8") + img.header.stamp = stamp + return img + + def cbMode(self, msg): return #TODO adjust self.active