diff --git a/src/demo/main.cpp b/src/demo/main.cpp index f34e2a5..3600a9e 100644 --- a/src/demo/main.cpp +++ b/src/demo/main.cpp @@ -72,20 +72,20 @@ int main() { vector vec_path; - GetFileNames("/home/share/data/villiage_test/test3", vec_path); + // GetFileNames("/home/share/data/villiage_test/test3", vec_path); // vec_path = GetFilesFromFile("./files1.log"); - // { - // string path = "./img/test_road2.jpg"; - // vec_path.push_back(path); - // } + { + string path = "/home/share/data/villiage_test/test3/192.168.10.67_01_20230601160330100_15.jpg"; + vec_path.push_back(path); + } size_t last_recoder = 0; int index = 0; int max_value = vec_path.size(); - while (true) + // while (true) { // for (size_t i = 0; i < vec_path.size(); i++) { @@ -94,10 +94,10 @@ int main() { vector vec_file_name; vec_file_name.push_back(vec_path[first_index]); - vec_file_name.push_back(vec_path[second_index]); + // vec_file_name.push_back(vec_path[second_index]); std::vector result = village_pic_analysis_file(vaHandle, vec_file_name); - // show_result(result, vec_path); + show_result(result, vec_path); size_t cur_recoder = GetDeviceMem(0); if (cur_recoder > last_recoder) @@ -187,7 +187,7 @@ void show_result(std::vector result, vector vec_path){ } LOG_INFO(" 号牌号码:{}{}{}{}{}{}{}{}", plate_info.recg[0].character, plate_info.recg[1].character, plate_info.recg[2].character, plate_info.recg[3].character, plate_info.recg[4].character, plate_info.recg[5].character, plate_info.recg[6].character, plate_info.recg[7].character); LOG_INFO(" 号牌可信度:{}", plate_info.detect_score); - LOG_INFO(" 每位号牌可信度:{}:{} {}:{} {}:{} {}:{} {}:{} {}:{} {}:{} {}:{}", plate_info.recg[0].character, plate_info.recg[0].maxprob, plate_info.recg[1].character, plate_info.recg[1].maxprob, plate_info.recg[2].character, plate_info.recg[2].maxprob, plate_info.recg[3].character, plate_info.recg[3].maxprob, plate_info.recg[4].character, plate_info.recg[4].maxprob, plate_info.recg[5].character, plate_info.recg[5].maxprob, plate_info.recg[6].character, plate_info.recg[6].maxprob, plate_info.recg[7].character, plate_info.recg[7].maxprob); + LOG_INFO(" 每位号牌可信度: {}:{} {}:{} {}:{} {}:{} {}:{} {}:{} {}:{} {}:{}", plate_info.recg[0].character, plate_info.recg[0].maxprob, plate_info.recg[1].character, plate_info.recg[1].maxprob, plate_info.recg[2].character, plate_info.recg[2].maxprob, plate_info.recg[3].character, plate_info.recg[3].maxprob, plate_info.recg[4].character, plate_info.recg[4].maxprob, plate_info.recg[5].character, plate_info.recg[5].maxprob, plate_info.recg[6].character, plate_info.recg[6].maxprob, plate_info.recg[7].character, plate_info.recg[7].maxprob); LOG_INFO(" 车辆类型分类:{}", vehicle_type[info[j].vpt_type]); } else { LOG_INFO("行人特征");