The information exchange methods currently used in the field of vehicle inspection are not in harmony with the social information construction environment, which hinders the interaction and flow of information. On the other hand, because a large amount of data collected by different types of sensors must be transmitted to edge computing nodes, dynamic vehicle detection will lead to network congestion and affect the calculation of edge computing nodes. Therefore, optimizing the data transmission between vehicles and edge computing nodes is a new challenge, which needs to be solved in the practical application of dynamic vehicle detection architecture based on edge computing. In this paper, we have considered the data requirements of dynamic vehicle detection in different environments, analyzed the optimization objectives and constraints, and proposed deviation detection and greedy algorithms to solve the problem of MILP solving the problem of long time and insufficient practical application, and evaluated the performance of the algorithm through simulation experiments using SUMO, a traffic flow simulation tool, and PreScan, a vehicle simulation test software. The results show that greedy algorithm is more suitable for practical application than deviation detection algorithm. The implementation of this system can improve the efficiency of vehicle detection and management, and has good application value.