赞
踩
LVI-SAM运行kitti 02
数据集时,IMU报错。
#!/usr/bin/env python # -*- coding: utf-8 -*- from datetime import datetime import matplotlib.pyplot as plt DESC = "Check timestamps files" def readfile(MyFile): list1 = [] try: file = open(MyFile, 'r') except FileNotFoundError: print('File is not found') else: lines = file.readlines() for line in lines: a = line.split() h, m, s = a[1].strip().split(":") list1.append(int(h) * 3600 + int(m) * 60 + float(s)) file.close() return list1 def drawGraph(x, y): plt.plot(x, y) plt.show() if __name__ == "__main__": import argparse parser = argparse.ArgumentParser(description=DESC) parser.add_argument("timestamps_file", help="imu timestamps file in KITTI raw") args = parser.parse_args() timestamps = readfile(args.timestamps_file) start_time = timestamps[0] for i in range(len(timestamps)): timestamps[i] = timestamps[i] - start_time #print(timestamps[0:10]) x = list(range(len(timestamps))) drawGraph(x, timestamps)
将图片放大后可以看到许多问题。
手动修改突起的数据部分
垂直变化的部分是IMU数据缺失,缺失有影响的话只能将后面的全部删除了吧???
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。