# Revision history [back]

I have same problem with python scripts . when I instanced a TransformListener object , and immediately called the waitForTransform function , it would throw a Extrapolation .

the code like this:

listener = tf.TransformListener()Give tf some time to fill its buffer
listener.waitForTransform("/goal_in_picture","/map",rospy.Time.now(),rospy.Duration(5.0))


but After I referred @Pi Robot scripts , I add a delay line to give tf some time to fill its buffer,like this:

listener = tf.TransformListener()Give tf some time to fill its buffer
# Give tf some time to fill its buffer
rospy.sleep(2)
listener.waitForTransform("/goal_in_picture","/map",rospy.Time.now(),rospy.Duration(5.0))


and amazing happened . I hope it will help .

I have same problem with python scripts . when I instanced a TransformListener object , and immediately called the waitForTransform function , it would throw a Extrapolation .

see my question ,please paunch here

the code like this:

listener = tf.TransformListener()Give tf some time to fill its buffer
listener.waitForTransform("/goal_in_picture","/map",rospy.Time.now(),rospy.Duration(5.0))


but After I referred @Pi Robot scripts , I add a delay line to give tf some time to fill its buffer,like this:

listener = tf.TransformListener()Give tf some time to fill its buffer
# Give tf some time to fill its buffer
rospy.sleep(2)
listener.waitForTransform("/goal_in_picture","/map",rospy.Time.now(),rospy.Duration(5.0))


and amazing happened . I hope it will help .

I have same problem with python scripts . when I instanced a TransformListener object , and immediately called the waitForTransform function , it would throw a Extrapolation .

see my question ,please paunch here

the code like this:

listener = tf.TransformListener()Give tf some time to fill its buffer
tf.TransformListener()
listener.waitForTransform("/goal_in_picture","/map",rospy.Time.now(),rospy.Duration(5.0))


but After I referred @Pi Robot scripts , I add a delay line to give tf some time to fill its buffer,like this:

listener = tf.TransformListener()Give tf some time to fill its buffer
tf.TransformListener()
# Give tf some time to fill its buffer
rospy.sleep(2)
listener.waitForTransform("/goal_in_picture","/map",rospy.Time.now(),rospy.Duration(5.0))


and amazing happened . I hope it will help .

I have same problem with python scripts . when I instanced a TransformListener object , and immediately called the waitForTransform function , it would throw a Extrapolation .

see my question ,please paunch punch here

the code like this:

listener = tf.TransformListener()
listener.waitForTransform("/goal_in_picture","/map",rospy.Time.now(),rospy.Duration(5.0))


but After I referred @Pi Robot scripts , I add a delay line to give tf some time to fill its buffer,like this:

listener = tf.TransformListener()
# Give tf some time to fill its buffer
rospy.sleep(2)
listener.waitForTransform("/goal_in_picture","/map",rospy.Time.now(),rospy.Duration(5.0))


and amazing happened . I hope it will help .

I have same problem with python scripts . when I instanced a TransformListener object , and immediately called the waitForTransform function , it would throw a Extrapolation .

see my question ,please punch here

the code like this:

listener = tf.TransformListener()
listener.waitForTransform("/goal_in_picture","/map",rospy.Time.now(),rospy.Duration(5.0))


but After I referred to @Pi Robot scripts , I add a delay line to give tf some time to fill its buffer,like this:

listener = tf.TransformListener()
# Give tf some time to fill its buffer
rospy.sleep(2)
listener.waitForTransform("/goal_in_picture","/map",rospy.Time.now(),rospy.Duration(5.0))


and amazing happened . I hope it will help .