Throttle not working
I get:
ExtrapolationException: Lookup would require extrapolation into the past. Requested time 1240.327000000 but the earliest data is at time 1240.793000000, when looking up transform from frame [map] to frame
tf
is giving me issues when I try to use it, I have tried using
throttling
to increase the rate of publishing to tf
(3000hz and above) and it didn't help. I make use of tf in this function here:
def transform(self,coord,from_frame='map',to_frame='base_scan'):
self.listener.waitForTransform(from_frame,to_frame,rospy.get_rostime(),rospy.Duration(5.5))
self.scope.header.frame_id = from_frame
self.scope.header.stamp = rospy.get_rostime() # rospy.TIme(0)
self.scope.point.x = coord[0]
self.scope.point.y = coord[1]
self.scope.point.z = 0
p = self.listener.transformPoint(to_frame,self.scope)
print("TOOOOOOOOOAAAAAAAAAASSSSSSSSSSSSSSTTTTTTTTTTT")
return [p.point.x,p.point.y]
I use this function in a for loop to change several points from map to base_scan frame. I just print out tooasst to see how effectively the points are being converted and the terminal fluctutates between sevral lines of toast and several lines of said error. Is there any other thing I can do to make the error go away?