# kitti_detection_eval **Repository Path**: chengc/kitti_detection_eval ## Basic Information - **Project Name**: kitti_detection_eval - **Description**: KITTI官方评估脚本 [format: gt-txt; det-txt (each image)] - **Primary Language**: C - **License**: CC-BY-SA-4.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2020-02-19 - **Last Updated**: 2020-12-19 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # kitti_detection_eval #### **介绍** 修改KITTI官方评估脚本,方便进行测评。 - 修改cpp中的测评图像数量,测试数据集按照1:1划分,3741张图片用于训练,3740张图片用于测评 - 修改label的路径为:label_2_ori_eval/,其中已对数据集做了一定处理(删除不相关的类别数据,TXT文件与模型输出的TXT文件一一对应) - 修改results的路径为:results/,其中在运行评估脚本时会指定参数result_sha,所以真实路径为:results/result_sha - 添加几个脚本文件 ``` cp_gt_for_eval.py:根据测试结果文件名复制对应的标签文件 file_name_change.py:批量修改文件名,0~N_TESTIMAGES parse.py:对官方评估脚本生成的临时文件进行解析,获得各个类别的AP和mAP ``` #### **使用** - 编译 ``` sudo apt-get install cmake sudo apt-get install libboost-all-dev # for boost sudo apt-get install libx11-dev # for gnuplot and pdfcrop sudo apt-get install gnuplot sudo apt install texlive-extra-utils cmake . make ``` - 准备 ``` 将模型输出结果转换成kitti格式的TXT文件放置于文件夹result_sha中; 运行脚本cp_gt_for_eval.py复制对应标签文件于文件夹label_2_ori_eval中; 运行脚本file_name_change.py修改TXT的文件名; (注意修改相关路径) ``` - 运行 ``` ./evaluate_object result_sha ``` - 结果 ``` 在目录results/result_sha下会生成临时TXT文件(e.g. stats_car_detection.txt),用于解析得到类别AP; 并新建plot文件夹用于放置绘制的PR曲线图; 运行脚本文件parse.py以获得各个类别的AP和mAP ``` #### **Copyright** This work is a derivative of [The KITTI Vision Benchmark Suite](http://www.cvlibs.net/datasets/kitti/eval_object.php) by A. Geiger, P. Lenz, C. Stiller and R. Urtasun, and [eval_kitti](https://github.com/cguindel/eval_kitti) by cguindel, used under CC BY-NC-SA. Consequently, code in this repository is published under the same [Creative Commons Attribution-NonCommercial-ShareAlike 4.0 License](). This means that you must attribute the work in the manner specified by the authors, you may not use this work for commercial purposes and if you alter, transform, or build upon this work, you may distribute the resulting work only under the same license.