SLAM精度测评

您所在的位置:网站首页 三菱evo测评 SLAM精度测评

SLAM精度测评

2023-07-15 10:05| 来源: 网络整理| 查看: 265

1.install

GitHub - MichaelGrupp/evo: Python package for the evaluation of odometry and SLAM

注意:安装好依赖!

sudo apt install python-pip pip install evo --upgrade --no-binary evo or pip install evo --upgrade --no-binary evo --user pip install numpy --upgrade --user 2.数据格式(data formal):TUM/EuRoC/Kitti数据集 格式转换 3数据格式转换 3.1"把EuRoc的数据格式转化成TUM数据格式"

evo_traj euroc data.csv --save_as_tum

将生成的 KeyFrameNavStateTrajectory.txt 文件,格式如下。总共17位  (timestamp;position3;q4;v3;bw3;ba3)

转化成符合TUM 形式的轨迹文件格式:8位

timestamp x y z q_x q_y q_z q_w

3.2"TUM数据转换成kitti格式" evo_traj tum traj_1.txt  traj_2.txt  traj_3.txt  --save_as_kitti 3.3"TUM数据转换成kitti格式" " 把一些文件的数据格式转化成rosbag" evo_traj tum traj_1.txt traj_2.txt traj_3.txt --save_as_bag

4.evo使用 evo_traj euroc v203_truth.csv --plot

2.Plot multiple trajectories Here, we plot two KITTI pose files and the ground truth using evo_traj: cd test/data evo_traj kitti KITTI_00_ORB.txt KITTI_00_SPTAM.txt --ref=KITTI_00_gt.txt -p --plot_mode=xz 3.Run a metric on trajectories 3.1 evo_ape

绝对位姿误差,常被用作绝对轨迹误差,比较估计轨迹和参考轨迹并计算整个轨迹的统计数据,适用于测试轨迹的全局一致性。 命令语法:命令 格式 参考轨迹 估计轨迹 [可选项] 其中格式包括euroc、tum等数据格式,可选项有对齐命令、画图、保存结果等。

For example, here we calculate the absolute pose error for two trajectories from ORB-SLAM and S-PTAM using evo_ape (KITTI_00_gt.txt is the reference (ground truth)) and plot and save the individual results to .zip files for evo_res:

mkdir results evo_ape kitti KITTI_00_gt.txt KITTI_00_ORB.txt -r full -va --plot --plot_mode xz --save_results results/ORB.zip

 命令的含义为:计算考虑平移和旋转部分误差的ape,进行平移和旋转对齐,以详细模式显示,保存画图并保存计算结果。 命令运行后得到结果如下图所示

 

其中-r表示ape所基于的姿态关系

 

不添加-r/–pose_relation和可选项,则默认为trans_part。

-v表示verbose mode,详细模式,-a表示采用SE(3) Umeyama对齐,其余可选项如下表所示。不加-s表示默认尺度对齐参数为1.0,即不进行尺度对齐。

 详情:

可通过 evo_ape +数据格式 + --help查看更多参数的含义以及如何使用。例如 evo_ape euroc --help

3.2 evo_rpe

相对位姿误差不进行绝对位姿的比较,相对位姿误差比较运动(姿态增量)。相对位姿误差可以给出局部精度,例如slam系统每米的平移或者旋转漂移量。

命令语法:命令 格式 参考轨迹 估计轨迹 [可选项] 其中格式包括euroc、tum等数据格式,可选项有对齐命令、画图、保存结果等。 常用命令示例:

evo_rpe euroc data.csv V102.txt -r angle_deg --delta 1 --delta_unit m -va --plot --plot_mode xyz --save_plot ./VIO --save_results ./VIO.zip

 命令的含义为 求每米考虑旋转角的rpe,以详细模式显示并画图。 命令运行后得到结果如下图所示

其中-r表示ape所基于的姿态关系

 不添加-r/–pose_relation和可选项,则默认为trans_part。 –d/–delta表示相对位姿之间的增量,–u/–delta_unit表示增量的单位,可选参数为[f, d, r, m],分别表示[frames, deg, rad, meters]。–d/–delta -u/–delta_unit合起来表示衡量局部精度的单位,如每米,每弧度,每百米等。其中–delta_unit为f时,–delta的参数必须为整形,其余情况下可以为浮点型。–delta 默认为1,–delta_unit默认为f。 -v --plot --plot_mode xyz --save_results results/VINS.zip --save_plot等同evo_ape中所讲。 当在命令中加上–all_pairs,则计算rpe时使用位置数据中所有的对而不是仅连续对,此时,可以通过-t/–delta_tol控制–all_pairs模式下的相对增量的容差(relative delta tolerance)。需要注意–all_pairs下不能使用–plot函数。 可通过 evo_rpe +数据格式 + --help查看更多参数的含义以及如何使用。例如 evo_rpe euroc --help

4.Process multiple results from a metric

evo_res can be used to compare multiple result files from the metrics, i.e

print infos and statistics (default)plot the resultssave the statistics in a table

Here, we use the results from above to generate a plot and a table:

evo_ape/evo_rpe中将结果保存为.zip文件后,可以利用evo_res对不同的结果进行比较。

evo_res results/*.zip -p --save_table results/table.csv

evo_res --help可查看可选参数含义。

evo其他常用命令

结果如下所示:

参考evo: GitHub - MichaelGrupp/evo: Python package for the evaluation of odometry and SLAM



【本文地址】


今日新闻


推荐新闻


CopyRight 2018-2019 办公设备维修网 版权所有 豫ICP备15022753号-3