In order to solve the problems of defects and damage in underwater pipelines caused by dirt in water, corrosion of seawater, wear and tear in operation, this paper presents an autonomous inspection robot system based on optical vision technology and conducts experimental verification by making a prototype. In order to ensure the full effectiveness of the camera field of view, a motion controller was designed by using light vision technology. During the operation of the controller, the front camera was used as the center of the motion circle to realize the tracking deviation angle and displacement deviation correction. An anomaly synthesis evaluation algorithm based on the YOLOV4-Tiny model was proposed to dynamically evaluate the image data of the motion process which effectively avoided the problems of misidentification, insufficient data utilization and poor synchronization caused by the limited accuracy of the model. Many continuous underwater experiments show that the autonomous inspection robot can track the underwater pipeline accurately in the horizontal and vertical directions, and the motion accuracy is 100%; it can accurately identify the position and shape of the adsorbates on the underwater pipeline, and the recognition accuracy is 96%.