In the research of motion video, the existing target detection methods are susceptible to changes in the motion video scene and cannot accurately detect the motion state of the target. Moving target detection technology is an important branch of computer vision technology. Its function is to implement real-time monitoring, real-time video capture, and detection of objects in the target area and store information that users are interested in as an important basis for exercise. This article focuses on how to efficiently perform motion detection on real-time video. By introducing the mathematical model of image processing, the traditional motion detection algorithm is improved and the improved motion detection algorithm is implemented in the system. This article combines the advantages of the widely used frame difference method, target detection algorithm, and background difference method and introduces the moving object detection method combining these two algorithms. When using Gaussian mixture model for modeling, improve the parts with differences, and keep the unmatched Gaussian distribution so that the modeling effect is similar to the actual background; the binary image is obtained through the difference between frames and the threshold, and the motion change domain is extracted through mathematical morphological filtering, and finally, the moving target is detected. The experiment proved the following: when there are more motion states, the recall rate is slightly better than that of the VIBE algorithm. It decreased about 0.05 or so, but the relative accuracy rate increased by about 0.12, and the increase ratio is significantly higher than the decrease ratio. Departments need to adopt effective target extraction methods. In order to improve the accuracy of moving target detection, this paper studies the method of background model establishment and target extraction and proposes its own improvement.