def METHOD_NAME(self, filename, duration, pts):
    rospy.sleep(rospy.Duration(0.5))
    correct = self.get_ideal_response(pts)
    print(f"Correct pose: {np.degrees(correct.pose.theta)}")
    bag = rosbag.Bag(filename)
    first = True
    first_time = None
    previous_time = None
    for topic, msg, t in bag.read_messages():
        if first:
            first_time = t
            previous_time = t
            first = False
        else:
            rospy.sleep(t - previous_time)  # Slow down to watch happen
            previous_time = t
            if t - first_time > duration:
                break
        if topic == self.img_topic:
            self.img_pub.publish(msg)
        if topic == self.info_topic:
            self.cam_info_pub.publish(msg)
    res = self.service(VisionRequest2DRequest())
    msg = "Marker not found after playing bag"
    self.assertTrue(res.found, msg=msg)
    # 10 pixel error accepted
    res_xy = np.array([res.pose.x, res.pose.y])
    correct_xy = np.array([correct.pose.x, correct.pose.y])
    err = np.linalg.norm(res_xy - correct_xy)
    msg = "Marker pose (x,y) too much error Res={} Correct={} Error={}".format(
        res_xy,
        correct_xy,
        err,
    )
    self.assertLess(
        err,
        20.0,
        # A little bit of tolerance given in precise ground truth. Will lower when new label system
        msg=msg,
    )
    # 5 degrees error accepted
    theta_err = abs(
        np.arctan2(
            np.sin(res.pose.theta - correct.pose.theta),
            np.cos(res.pose.theta - correct.pose.theta),
        ),
    )
    msg = "Marker pose angle (theta) too much error Res={} Correct={} Error={}".format(
        np.degrees(res.pose.theta),
        np.degrees(correct.pose.theta),
        np.degrees(theta_err),
    )
    self.assertLess(theta_err, 0.15, msg=msg)