| | |
| | | import java.util.stream.Collectors; |
| | | |
| | | /** |
| | | * 计算车辆数据完整性 |
| | | * 计算车辆数据完整性(检测车牌号、车牌颜色啥的合不合标准 |
| | | * 采用数据完整性监测接口 |
| | | * 获取分省厅、区域的map<k,v> k为deptId或者Province_deptId |
| | | * 更新或新增 |
| | | */ |
| | |
| | | areaStatsMap.forEach((deptId, stats) -> { |
| | | if (stats.totalSites > 0) { |
| | | CheckIndexCar checkIndexCar = createOrUpdateCheckIndexCar(deptId, stats, checkIndexCarList); |
| | | checkIndexCars.add(checkIndexCar); |
| | | if (checkIndexCar != null) { |
| | | checkIndexCars.add(checkIndexCar); |
| | | } |
| | | } |
| | | }); |
| | | |
| | |
| | | AreaStats stats = areaStatsMap.computeIfAbsent(key, k -> new AreaStats()); |
| | | stats.totalSites++; |
| | | //90%及以上数据合格则此车辆卡口设备被视为抓拍数据完整 |
| | | if(result.getMainNoIntegrityPercent() <= 0.1){ |
| | | if (result.getMainNoIntegrityPercent() <= 0.1) { |
| | | stats.integritySites++; |
| | | } |
| | | //重点点位为六项属性 |
| | | if(importantIds.contains(key)){ |
| | | if (importantIds.contains(key)) { |
| | | stats.importantTotalSites++; |
| | | if(result.getNoIntegrityPercent() <= 0.1){ |
| | | if (result.getNoIntegrityPercent() <= 0.1) { |
| | | stats.importantIntegritySites++; |
| | | } |
| | | } |
| | |
| | | * 车辆信息采集正确率 |
| | | */ |
| | | private CheckIndexCar createOrUpdateCheckIndexCar(String key, AreaStats stats, List<CheckIndexCar> checkIndexCarList) { |
| | | CheckIndexCar checkIndexCar = getCheckIndex(key, checkIndexCarList); |
| | | CheckIndexCar checkIndexCar = getCheckIndex(key, checkIndexCarList, CheckIndexCar.class); |
| | | if (checkIndexCar == null) { |
| | | return null; |
| | | } |
| | | //调用计算方法 |
| | | Map<String, Object> param = new HashMap<>(); |
| | | param.put("totalSites", stats.totalSites); |