line = np.array([[lx, ly],[cx, cy]], dtype=np.int32)
trajectoryImg = cv2.polylines(trajectoryImg, [line], 1, (0, 0, 0))
记得swap # 绘制小鼠的轨迹 trajectoryImg = trajectoryImg.swapaxes(0, 1)