Correction method for patent certificate image with any inclination angle

The invention discloses a correction method for a patent certificate image with any inclination angle. The correction method comprises the following steps: graying the input patent certificate image and then performing Gaussian filter; performing Canny edge detection on the filtered image to obtain a basic skeleton line of the certificate image; acquiring the inclination angle of the skeleton line by using Hough transformation; obtaining the inclination angle of the first correction according to the principle that the minority is subordinate to the majority and then rotating the image; next, judging the inclination angle of the second correction according to the position of a round stamp in the certificate image corrected for the first time; and rotating the image according to the inclination angle to finally finish the inclination correction of the patent certificate image.