{"id":1071114,"date":"2025-01-08T11:04:22","date_gmt":"2025-01-08T03:04:22","guid":{"rendered":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/1071114.html"},"modified":"2025-01-08T11:04:24","modified_gmt":"2025-01-08T03:04:24","slug":"%e5%a6%82%e4%bd%95%e7%94%a8python%e9%80%89%e6%8b%a9%e5%9b%be%e5%83%8f%e7%9a%84%e7%89%b9%e5%be%81%e5%8c%ba%e5%9f%9f-2","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/1071114.html","title":{"rendered":"\u5982\u4f55\u7528python\u9009\u62e9\u56fe\u50cf\u7684\u7279\u5f81\u533a\u57df"},"content":{"rendered":"<p style=\"text-align:center;\" ><img decoding=\"async\" src=\"https:\/\/cdn-kb.worktile.com\/kb\/wp-content\/uploads\/2024\/04\/25101704\/ec36f775-2b28-4fb5-af27-30ed2216447d.webp\" alt=\"\u5982\u4f55\u7528python\u9009\u62e9\u56fe\u50cf\u7684\u7279\u5f81\u533a\u57df\" \/><\/p>\n<p><p> <strong>\u4f7f\u7528Python\u9009\u62e9\u56fe\u50cf\u7684\u7279\u5f81\u533a\u57df\u7684\u65b9\u6cd5\u6709\uff1a\u4f7f\u7528OpenCV\u8fdb\u884c\u8fb9\u7f18\u68c0\u6d4b\u3001\u4f7f\u7528SIFT\/SURF\u8fdb\u884c\u7279\u5f81\u63d0\u53d6\u3001\u4f7f\u7528Harris\u89d2\u70b9\u68c0\u6d4b\u3001\u4f7f\u7528\u533a\u57df\u751f\u957f\u7b97\u6cd5\u3002<\/strong> <\/p>\n<\/p>\n<p><p>\u5176\u4e2d\uff0c<strong>\u4f7f\u7528OpenCV\u8fdb\u884c\u8fb9\u7f18\u68c0\u6d4b<\/strong>\u662f\u4e00\u79cd\u5e38\u89c1\u4e14\u9ad8\u6548\u7684\u65b9\u6cd5\u3002\u8fb9\u7f18\u68c0\u6d4b\u901a\u8fc7\u68c0\u6d4b\u56fe\u50cf\u4e2d\u50cf\u7d20\u503c\u53d8\u5316\u663e\u8457\u7684\u533a\u57df\u6765\u8bc6\u522b\u56fe\u50cf\u7684\u7279\u5f81\u533a\u57df\u3002\u4ee5\u4e0b\u662f\u8be6\u7ec6\u63cf\u8ff0\u5982\u4f55\u4f7f\u7528OpenCV\u8fdb\u884c\u8fb9\u7f18\u68c0\u6d4b\u6765\u9009\u62e9\u56fe\u50cf\u7684\u7279\u5f81\u533a\u57df\u3002<\/p>\n<\/p>\n<p><h3>\u4f7f\u7528OpenCV\u8fdb\u884c\u8fb9\u7f18\u68c0\u6d4b<\/h3>\n<\/p>\n<p><p>OpenCV\uff08Open Source Computer Vision Library\uff09\u662f\u4e00\u4e2a\u5f00\u6e90\u8ba1\u7b97\u673a\u89c6\u89c9\u548c<a href=\"https:\/\/docs.pingcode.com\/ask\/59192.html\" target=\"_blank\">\u673a\u5668\u5b66\u4e60<\/a>\u8f6f\u4ef6\u5e93\u3002\u5b83\u5305\u542b\u4e86\u6570\u767e\u79cd\u8ba1\u7b97\u673a\u89c6\u89c9\u7b97\u6cd5\uff0c\u662f\u56fe\u50cf\u5904\u7406\u548c\u7279\u5f81\u63d0\u53d6\u7684\u5f3a\u5927\u5de5\u5177\u3002\u8fb9\u7f18\u68c0\u6d4b\u662f\u56fe\u50cf\u5904\u7406\u4e2d\u7684\u4e00\u79cd\u57fa\u7840\u6280\u672f\uff0c\u7528\u4e8e\u68c0\u6d4b\u56fe\u50cf\u4e2d\u5b58\u5728\u7a81\u53d8\u7684\u50cf\u7d20\u70b9\uff0c\u4ece\u800c\u8bc6\u522b\u7269\u4f53\u7684\u8f6e\u5ed3\u548c\u7279\u5f81\u533a\u57df\u3002<\/p>\n<\/p>\n<p><h4>\u5b89\u88c5OpenCV<\/h4>\n<\/p>\n<p><p>\u5728\u5f00\u59cb\u4f7f\u7528OpenCV\u4e4b\u524d\uff0c\u9700\u8981\u786e\u4fdd\u5df2\u7ecf\u5b89\u88c5\u4e86OpenCV\u5e93\u3002\u5982\u679c\u6ca1\u6709\u5b89\u88c5\uff0c\u53ef\u4ee5\u901a\u8fc7\u4ee5\u4e0b\u547d\u4ee4\u5b89\u88c5\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-bash\">pip install opencv-python<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>\u8bfb\u53d6\u56fe\u50cf<\/h4>\n<\/p>\n<p><p>\u9996\u5148\uff0c\u4f7f\u7528OpenCV\u8bfb\u53d6\u56fe\u50cf\u3002\u5047\u8bbe\u6211\u4eec\u6709\u4e00\u5f20\u540d\u4e3a<code>example.jpg<\/code>\u7684\u56fe\u50cf\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import cv2<\/p>\n<h2><strong>\u8bfb\u53d6\u56fe\u50cf<\/strong><\/h2>\n<p>image = cv2.imread(&#39;example.jpg&#39;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>\u8f6c\u6362\u4e3a\u7070\u5ea6\u56fe\u50cf<\/h4>\n<\/p>\n<p><p>\u8fb9\u7f18\u68c0\u6d4b\u901a\u5e38\u5728\u7070\u5ea6\u56fe\u50cf\u4e0a\u8fdb\u884c\uff0c\u56e0\u6b64\u9700\u8981\u5c06\u5f69\u8272\u56fe\u50cf\u8f6c\u6362\u4e3a\u7070\u5ea6\u56fe\u50cf\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\"># \u8f6c\u6362\u4e3a\u7070\u5ea6\u56fe\u50cf<\/p>\n<p>gray_image = cv2.cvtColor(image, cv2.COLOR_BGR2GRAY)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>\u5e94\u7528\u9ad8\u65af\u6a21\u7cca<\/h4>\n<\/p>\n<p><p>\u4e3a\u4e86\u51cf\u5c11\u566a\u58f0\u5e76\u907f\u514d\u68c0\u6d4b\u5230\u4e0d\u5fc5\u8981\u7684\u8fb9\u7f18\uff0c\u53ef\u4ee5\u5e94\u7528\u9ad8\u65af\u6a21\u7cca\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\"># \u5e94\u7528\u9ad8\u65af\u6a21\u7cca<\/p>\n<p>blurred_image = cv2.GaussianBlur(gray_image, (5, 5), 0)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>\u4f7f\u7528Canny\u8fb9\u7f18\u68c0\u6d4b<\/h4>\n<\/p>\n<p><p>Canny\u8fb9\u7f18\u68c0\u6d4b\u662f\u4e00\u79cd\u5e38\u7528\u7684\u8fb9\u7f18\u68c0\u6d4b\u7b97\u6cd5\uff0c\u5177\u6709\u826f\u597d\u7684\u68c0\u6d4b\u6027\u80fd\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\"># \u4f7f\u7528Canny\u8fb9\u7f18\u68c0\u6d4b<\/p>\n<p>edges = cv2.Canny(blurred_image, 50, 150)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>\u663e\u793a\u8fb9\u7f18\u68c0\u6d4b\u7ed3\u679c<\/h4>\n<\/p>\n<p><p>\u4f7f\u7528OpenCV\u663e\u793a\u8fb9\u7f18\u68c0\u6d4b\u7684\u7ed3\u679c\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\"># \u663e\u793a\u8fb9\u7f18\u68c0\u6d4b\u7ed3\u679c<\/p>\n<p>cv2.imshow(&#39;Edges&#39;, edges)<\/p>\n<p>cv2.w<a href=\"https:\/\/docs.pingcode.com\/blog\/59162.html\" target=\"_blank\">AI<\/a>tKey(0)<\/p>\n<p>cv2.destroyAllWindows()<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u901a\u8fc7\u4e0a\u8ff0\u6b65\u9aa4\uff0c\u6211\u4eec\u53ef\u4ee5\u6210\u529f\u5730\u4f7f\u7528OpenCV\u8fdb\u884c\u8fb9\u7f18\u68c0\u6d4b\u6765\u9009\u62e9\u56fe\u50cf\u7684\u7279\u5f81\u533a\u57df\u3002\u8fb9\u7f18\u68c0\u6d4b\u540e\uff0c\u53ef\u4ee5\u5bf9\u7279\u5f81\u533a\u57df\u8fdb\u884c\u8fdb\u4e00\u6b65\u7684\u5904\u7406\u548c\u5206\u6790\u3002<\/p>\n<\/p>\n<p><h3>\u4f7f\u7528SIFT\/SURF\u8fdb\u884c\u7279\u5f81\u63d0\u53d6<\/h3>\n<\/p>\n<p><p>SIFT\uff08Scale-Invariant Feature Transform\uff09\u548cSURF\uff08Speeded-Up Robust Features\uff09\u662f\u4e24\u79cd\u5e38\u7528\u7684\u7279\u5f81\u63d0\u53d6\u7b97\u6cd5\u3002\u5b83\u4eec\u80fd\u591f\u68c0\u6d4b\u56fe\u50cf\u4e2d\u7684\u5173\u952e\u70b9\u5e76\u8ba1\u7b97\u63cf\u8ff0\u7b26\u3002SIFT\u548cSURF\u7684\u4f18\u70b9\u5728\u4e8e\u5b83\u4eec\u5bf9\u5c3a\u5ea6\u548c\u65cb\u8f6c\u5177\u6709\u4e0d\u53d8\u6027\u3002<\/p>\n<\/p>\n<p><h4>\u5b89\u88c5SIFT\/SURF<\/h4>\n<\/p>\n<p><p>\u7531\u4e8e\u4e13\u5229\u95ee\u9898\uff0cSIFT\u548cSURF\u5728OpenCV 3.4.2\u4e4b\u540e\u88ab\u79fb\u9664\u4e86\u3002\u5982\u679c\u9700\u8981\u4f7f\u7528\u8fd9\u4e9b\u7b97\u6cd5\uff0c\u53ef\u4ee5\u5b89\u88c5<code>opencv-contrib-python<\/code>\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-bash\">pip install opencv-contrib-python<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>\u8bfb\u53d6\u56fe\u50cf\u5e76\u8f6c\u6362\u4e3a\u7070\u5ea6\u56fe\u50cf<\/h4>\n<\/p>\n<p><pre><code class=\"language-python\">import cv2<\/p>\n<h2><strong>\u8bfb\u53d6\u56fe\u50cf<\/strong><\/h2>\n<p>image = cv2.imread(&#39;example.jpg&#39;)<\/p>\n<h2><strong>\u8f6c\u6362\u4e3a\u7070\u5ea6\u56fe\u50cf<\/strong><\/h2>\n<p>gray_image = cv2.cvtColor(image, cv2.COLOR_BGR2GRAY)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>\u4f7f\u7528SIFT\u8fdb\u884c\u7279\u5f81\u63d0\u53d6<\/h4>\n<\/p>\n<p><pre><code class=\"language-python\"># \u521b\u5efaSIFT\u5bf9\u8c61<\/p>\n<p>sift = cv2.SIFT_create()<\/p>\n<h2><strong>\u68c0\u6d4b\u5173\u952e\u70b9\u5e76\u8ba1\u7b97\u63cf\u8ff0\u7b26<\/strong><\/h2>\n<p>keypoints, descriptors = sift.detectAndCompute(gray_image, None)<\/p>\n<h2><strong>\u7ed8\u5236\u5173\u952e\u70b9<\/strong><\/h2>\n<p>image_with_keypoints = cv2.drawKeypoints(image, keypoints, None, color=(0, 255, 0))<\/p>\n<h2><strong>\u663e\u793a\u7ed3\u679c<\/strong><\/h2>\n<p>cv2.imshow(&#39;SIFT Keypoints&#39;, image_with_keypoints)<\/p>\n<p>cv2.waitKey(0)<\/p>\n<p>cv2.destroyAllWindows()<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>\u4f7f\u7528SURF\u8fdb\u884c\u7279\u5f81\u63d0\u53d6<\/h4>\n<\/p>\n<p><pre><code class=\"language-python\"># \u521b\u5efaSURF\u5bf9\u8c61<\/p>\n<p>surf = cv2.xfeatures2d.SURF_create()<\/p>\n<h2><strong>\u68c0\u6d4b\u5173\u952e\u70b9\u5e76\u8ba1\u7b97\u63cf\u8ff0\u7b26<\/strong><\/h2>\n<p>keypoints, descriptors = surf.detectAndCompute(gray_image, None)<\/p>\n<h2><strong>\u7ed8\u5236\u5173\u952e\u70b9<\/strong><\/h2>\n<p>image_with_keypoints = cv2.drawKeypoints(image, keypoints, None, color=(0, 255, 0))<\/p>\n<h2><strong>\u663e\u793a\u7ed3\u679c<\/strong><\/h2>\n<p>cv2.imshow(&#39;SURF Keypoints&#39;, image_with_keypoints)<\/p>\n<p>cv2.waitKey(0)<\/p>\n<p>cv2.destroyAllWindows()<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h3>\u4f7f\u7528Harris\u89d2\u70b9\u68c0\u6d4b<\/h3>\n<\/p>\n<p><p>Harris\u89d2\u70b9\u68c0\u6d4b\u662f\u4e00\u79cd\u7ecf\u5178\u7684\u89d2\u70b9\u68c0\u6d4b\u7b97\u6cd5\uff0c\u80fd\u591f\u68c0\u6d4b\u56fe\u50cf\u4e2d\u7684\u89d2\u70b9\u4f5c\u4e3a\u7279\u5f81\u533a\u57df\u3002<\/p>\n<\/p>\n<p><h4>\u8bfb\u53d6\u56fe\u50cf\u5e76\u8f6c\u6362\u4e3a\u7070\u5ea6\u56fe\u50cf<\/h4>\n<\/p>\n<p><pre><code class=\"language-python\">import cv2<\/p>\n<p>import numpy as np<\/p>\n<h2><strong>\u8bfb\u53d6\u56fe\u50cf<\/strong><\/h2>\n<p>image = cv2.imread(&#39;example.jpg&#39;)<\/p>\n<h2><strong>\u8f6c\u6362\u4e3a\u7070\u5ea6\u56fe\u50cf<\/strong><\/h2>\n<p>gray_image = cv2.cvtColor(image, cv2.COLOR_BGR2GRAY)<\/p>\n<h2><strong>\u8f6c\u6362\u4e3a\u6d6e\u70b9\u578b\u56fe\u50cf<\/strong><\/h2>\n<p>gray_image = np.float32(gray_image)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>\u4f7f\u7528Harris\u89d2\u70b9\u68c0\u6d4b<\/h4>\n<\/p>\n<p><pre><code class=\"language-python\"># \u4f7f\u7528Harris\u89d2\u70b9\u68c0\u6d4b<\/p>\n<p>harris_corners = cv2.cornerHarris(gray_image, 2, 3, 0.04)<\/p>\n<h2><strong>\u6269\u5927\u89d2\u70b9\u6807\u8bb0<\/strong><\/h2>\n<p>harris_corners = cv2.dilate(harris_corners, None)<\/p>\n<h2><strong>\u8bbe\u7f6e\u9608\u503c\u5e76\u6807\u8bb0\u89d2\u70b9<\/strong><\/h2>\n<p>threshold = 0.01 * harris_corners.max()<\/p>\n<p>image[harris_corners &gt; threshold] = [0, 0, 255]<\/p>\n<h2><strong>\u663e\u793a\u7ed3\u679c<\/strong><\/h2>\n<p>cv2.imshow(&#39;Harris Corners&#39;, image)<\/p>\n<p>cv2.waitKey(0)<\/p>\n<p>cv2.destroyAllWindows()<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h3>\u4f7f\u7528\u533a\u57df\u751f\u957f\u7b97\u6cd5<\/h3>\n<\/p>\n<p><p>\u533a\u57df\u751f\u957f\u662f\u4e00\u79cd\u5206\u5272\u7b97\u6cd5\uff0c\u901a\u8fc7\u4ece\u79cd\u5b50\u70b9\u5f00\u59cb\uff0c\u6839\u636e\u50cf\u7d20\u4e4b\u95f4\u7684\u76f8\u4f3c\u6027\u5c06\u533a\u57df\u9010\u6b65\u6269\u5c55\u3002\u533a\u57df\u751f\u957f\u9002\u7528\u4e8e\u4e00\u4e9b\u7279\u5b9a\u7684\u56fe\u50cf\u7279\u5f81\u533a\u57df\u9009\u62e9\u4efb\u52a1\u3002<\/p>\n<\/p>\n<p><h4>\u8bfb\u53d6\u56fe\u50cf\u5e76\u8f6c\u6362\u4e3a\u7070\u5ea6\u56fe\u50cf<\/h4>\n<\/p>\n<p><pre><code class=\"language-python\">import cv2<\/p>\n<p>import numpy as np<\/p>\n<h2><strong>\u8bfb\u53d6\u56fe\u50cf<\/strong><\/h2>\n<p>image = cv2.imread(&#39;example.jpg&#39;)<\/p>\n<h2><strong>\u8f6c\u6362\u4e3a\u7070\u5ea6\u56fe\u50cf<\/strong><\/h2>\n<p>gray_image = cv2.cvtColor(image, cv2.COLOR_BGR2GRAY)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>\u8bbe\u7f6e\u79cd\u5b50\u70b9\u548c\u9608\u503c<\/h4>\n<\/p>\n<p><pre><code class=\"language-python\"># \u8bbe\u7f6e\u79cd\u5b50\u70b9<\/p>\n<p>seed_point = (100, 100)  # \u6839\u636e\u5b9e\u9645\u60c5\u51b5\u9009\u62e9\u79cd\u5b50\u70b9<\/p>\n<h2><strong>\u8bbe\u7f6e\u9608\u503c<\/strong><\/h2>\n<p>threshold = 10<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>\u4f7f\u7528\u533a\u57df\u751f\u957f\u7b97\u6cd5<\/h4>\n<\/p>\n<p><pre><code class=\"language-python\"># \u521b\u5efa\u7a7a\u767d\u63a9\u7801<\/p>\n<p>mask = np.zeros_like(gray_image)<\/p>\n<h2><strong>\u5b9a\u4e49\u533a\u57df\u751f\u957f\u51fd\u6570<\/strong><\/h2>\n<p>def region_grow(image, mask, seed_point, threshold):<\/p>\n<p>    x, y = seed_point<\/p>\n<p>    rows, cols = image.shape<\/p>\n<p>    region = [(x, y)]<\/p>\n<p>    mask[x, y] = 255<\/p>\n<p>    while region:<\/p>\n<p>        x, y = region.pop(0)<\/p>\n<p>        for dx in [-1, 0, 1]:<\/p>\n<p>            for dy in [-1, 0, 1]:<\/p>\n<p>                if dx == 0 and dy == 0:<\/p>\n<p>                    continue<\/p>\n<p>                nx, ny = x + dx, y + dy<\/p>\n<p>                if 0 &lt;= nx &lt; rows and 0 &lt;= ny &lt; cols:<\/p>\n<p>                    if mask[nx, ny] == 0 and abs(int(image[nx, ny]) - int(image[x, y])) &lt; threshold:<\/p>\n<p>                        mask[nx, ny] = 255<\/p>\n<p>                        region.append((nx, ny))<\/p>\n<p>region_grow(gray_image, mask, seed_point, threshold)<\/p>\n<h2><strong>\u663e\u793a\u7ed3\u679c<\/strong><\/h2>\n<p>cv2.imshow(&#39;Region Growing&#39;, mask)<\/p>\n<p>cv2.waitKey(0)<\/p>\n<p>cv2.destroyAllWindows()<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u901a\u8fc7\u4e0a\u8ff0\u65b9\u6cd5\uff0c\u6211\u4eec\u53ef\u4ee5\u4f7f\u7528\u533a\u57df\u751f\u957f\u7b97\u6cd5\u4ece\u79cd\u5b50\u70b9\u5f00\u59cb\uff0c\u9010\u6b65\u9009\u62e9\u56fe\u50cf\u7684\u7279\u5f81\u533a\u57df\u3002<\/p>\n<\/p>\n<p><h3>\u603b\u7ed3<\/h3>\n<\/p>\n<p><p>\u5728\u8fd9\u7bc7\u6587\u7ae0\u4e2d\uff0c\u6211\u4eec\u4ecb\u7ecd\u4e86\u4f7f\u7528Python\u9009\u62e9\u56fe\u50cf\u7684\u7279\u5f81\u533a\u57df\u7684\u51e0\u79cd\u65b9\u6cd5\uff0c\u5305\u62ec\u4f7f\u7528OpenCV\u8fdb\u884c\u8fb9\u7f18\u68c0\u6d4b\u3001\u4f7f\u7528SIFT\/SURF\u8fdb\u884c\u7279\u5f81\u63d0\u53d6\u3001\u4f7f\u7528Harris\u89d2\u70b9\u68c0\u6d4b\u4ee5\u53ca\u4f7f\u7528\u533a\u57df\u751f\u957f\u7b97\u6cd5\u3002\u6bcf\u79cd\u65b9\u6cd5\u90fd\u6709\u5176\u72ec\u7279\u7684\u4f18\u52bf\u548c\u9002\u7528\u573a\u666f\uff0c\u9009\u62e9\u5408\u9002\u7684\u65b9\u6cd5\u53ef\u4ee5\u6709\u6548\u5730\u63d0\u53d6\u56fe\u50cf\u7684\u7279\u5f81\u533a\u57df\u3002\u5e0c\u671b\u8fd9\u7bc7\u6587\u7ae0\u80fd\u591f\u5e2e\u52a9\u4f60\u5728\u56fe\u50cf\u5904\u7406\u548c\u7279\u5f81\u63d0\u53d6\u65b9\u9762\u83b7\u5f97\u66f4\u591a\u7684\u7406\u89e3\u548c\u5b9e\u8df5\u7ecf\u9a8c\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p> <strong>\u5982\u4f55\u9009\u62e9\u56fe\u50cf\u7684\u7279\u5f81\u533a\u57df\u4ee5\u63d0\u9ad8\u5206\u6790\u51c6\u786e\u6027\uff1f<\/strong><br \/>\u9009\u62e9\u56fe\u50cf\u7684\u7279\u5f81\u533a\u57df\u53ef\u4ee5\u901a\u8fc7\u591a\u79cd\u6280\u672f\u5b9e\u73b0\u3002\u5e38\u7528\u7684\u65b9\u6cd5\u5305\u62ec\u4f7f\u7528\u8fb9\u7f18\u68c0\u6d4b\u7b97\u6cd5\uff08\u5982Canny\u8fb9\u7f18\u68c0\u6d4b\uff09\u3001\u89d2\u70b9\u68c0\u6d4b\uff08\u5982Harris\u89d2\u70b9\u68c0\u6d4b\uff09\u4ee5\u53ca\u533a\u57df\u751f\u957f\u7b97\u6cd5\u3002\u4f7f\u7528\u8fd9\u4e9b\u6280\u672f\u53ef\u4ee5\u5e2e\u52a9\u4f60\u8bc6\u522b\u56fe\u50cf\u4e2d\u91cd\u8981\u7684\u90e8\u5206\uff0c\u4ece\u800c\u63d0\u9ad8\u540e\u7eed\u5206\u6790\u7684\u51c6\u786e\u6027\u3002<\/p>\n<p><strong>\u5728Python\u4e2d\u6709\u54ea\u4e9b\u5e93\u53ef\u4ee5\u7528\u4e8e\u7279\u5f81\u533a\u57df\u9009\u62e9\uff1f<\/strong><br \/>\u5728Python\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528\u591a\u4e2a\u5e93\u6765\u9009\u62e9\u56fe\u50cf\u7684\u7279\u5f81\u533a\u57df\u3002OpenCV\u662f\u4e00\u4e2a\u5f3a\u5927\u7684\u8ba1\u7b97\u673a\u89c6\u89c9\u5e93\uff0c\u63d0\u4f9b\u4e86\u591a\u79cd\u56fe\u50cf\u5904\u7406\u5de5\u5177\u3002scikit-image\u5219\u662f\u53e6\u4e00\u79cd\u6d41\u884c\u7684\u5e93\uff0c\u9002\u5408\u4e8e\u56fe\u50cf\u7279\u5f81\u63d0\u53d6\u3002TensorFlow\u548cPyTorch\u4e5f\u53ef\u4ee5\u7528\u4e8e\u6784\u5efa\u6df1\u5ea6\u5b66\u4e60\u6a21\u578b\uff0c\u81ea\u52a8\u9009\u62e9\u548c\u63d0\u53d6\u56fe\u50cf\u7279\u5f81\u3002<\/p>\n<p><strong>\u5982\u4f55\u8bc4\u4f30\u9009\u62e9\u7684\u7279\u5f81\u533a\u57df\u7684\u6709\u6548\u6027\uff1f<\/strong><br \/>\u8bc4\u4f30\u7279\u5f81\u533a\u57df\u7684\u6709\u6548\u6027\u901a\u5e38\u53ef\u4ee5\u901a\u8fc7\u53ef\u89c6\u5316\u548c\u6027\u80fd\u6307\u6807\u6765\u5b9e\u73b0\u3002\u901a\u8fc7\u5c06\u9009\u62e9\u7684\u7279\u5f81\u533a\u57df\u4e0e\u5b9e\u9645\u611f\u5174\u8da3\u7684\u533a\u57df\u8fdb\u884c\u6bd4\u8f83\uff0c\u53ef\u4ee5\u76f4\u89c2\u5730\u5224\u65ad\u9009\u62e9\u7684\u51c6\u786e\u6027\u3002\u540c\u65f6\uff0c\u4f7f\u7528\u51c6\u786e\u7387\u3001\u53ec\u56de\u7387\u548cF1\u5206\u6570\u7b49\u6307\u6807\u6765\u8bc4\u4f30\u56fe\u50cf\u5206\u6790\u7ed3\u679c\u7684\u8d28\u91cf\uff0c\u80fd\u591f\u5e2e\u52a9\u4f60\u9a8c\u8bc1\u6240\u9009\u7279\u5f81\u533a\u57df\u7684\u6709\u6548\u6027\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"\u4f7f\u7528Python\u9009\u62e9\u56fe\u50cf\u7684\u7279\u5f81\u533a\u57df\u7684\u65b9\u6cd5\u6709\uff1a\u4f7f\u7528OpenCV\u8fdb\u884c\u8fb9\u7f18\u68c0\u6d4b\u3001\u4f7f\u7528SIFT\/SURF\u8fdb\u884c\u7279\u5f81\u63d0\u53d6\u3001 [&hellip;]","protected":false},"author":3,"featured_media":1071122,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[37],"tags":[],"acf":[],"_links":{"self":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1071114"}],"collection":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/comments?post=1071114"}],"version-history":[{"count":"1","href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1071114\/revisions"}],"predecessor-version":[{"id":1071123,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1071114\/revisions\/1071123"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/1071122"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=1071114"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=1071114"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=1071114"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}