{"id":1131849,"date":"2025-01-08T20:52:02","date_gmt":"2025-01-08T12:52:02","guid":{"rendered":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/1131849.html"},"modified":"2025-01-08T20:52:05","modified_gmt":"2025-01-08T12:52:05","slug":"%e5%a6%82%e4%bd%95%e7%94%a8python%e6%8a%93%e5%8f%96%e7%99%be%e5%ba%a6%e6%90%9c%e7%b4%a2%e6%95%b0%e6%8d%ae","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/1131849.html","title":{"rendered":"\u5982\u4f55\u7528python\u6293\u53d6\u767e\u5ea6\u641c\u7d22\u6570\u636e"},"content":{"rendered":"<p style=\"text-align:center;\" ><img decoding=\"async\" src=\"https:\/\/cdn-kb.worktile.com\/kb\/wp-content\/uploads\/2024\/04\/25101523\/181db249-9bdd-4749-a1fb-855d6cf7bf8a.webp\" alt=\"\u5982\u4f55\u7528python\u6293\u53d6\u767e\u5ea6\u641c\u7d22\u6570\u636e\" \/><\/p>\n<p><p> <strong>\u5982\u4f55\u7528Python\u6293\u53d6\u767e\u5ea6\u641c\u7d22\u6570\u636e<\/strong><\/p>\n<\/p>\n<p><p><strong>\u4f7f\u7528Python\u6293\u53d6\u767e\u5ea6\u641c\u7d22\u6570\u636e\u7684\u6838\u5fc3\u6b65\u9aa4\u5305\u62ec\uff1a\u9009\u62e9\u5408\u9002\u7684\u722c\u866b\u5de5\u5177\u3001\u8bbe\u7f6e\u8bf7\u6c42\u5934\u6a21\u62df\u6d4f\u89c8\u5668\u8bbf\u95ee\u3001\u5904\u7406\u53cd\u722c\u673a\u5236\u3001\u89e3\u6790\u7f51\u9875\u5185\u5bb9\u3002<\/strong> \u5176\u4e2d\uff0c\u5904\u7406\u53cd\u722c\u673a\u5236\u662f\u6700\u5173\u952e\u7684\u4e00\u6b65\u3002\u5728\u8fd9\u4e00\u6b65\u4e2d\uff0c\u6211\u4eec\u4f1a\u901a\u8fc7\u6a21\u62df\u7528\u6237\u884c\u4e3a\uff0c\u5982\u8bbe\u7f6e\u5408\u7406\u7684\u8bf7\u6c42\u95f4\u9694\u3001\u4f7f\u7528\u4ee3\u7406IP\u7b49\u624b\u6bb5\u6765\u907f\u514d\u88ab\u767e\u5ea6\u5c01\u7981\u3002<\/p>\n<\/p>\n<p><h3>\u4e00\u3001\u9009\u62e9\u5408\u9002\u7684\u722c\u866b\u5de5\u5177<\/h3>\n<\/p>\n<p><p>Python\u63d0\u4f9b\u4e86\u8bb8\u591a\u5f3a\u5927\u7684\u722c\u866b\u5de5\u5177\uff0c\u5982requests\u3001BeautifulSoup\u3001Scrapy\u7b49\u3002\u5bf9\u4e8e\u521d\u5b66\u8005\u6765\u8bf4\uff0crequests\u548cBeautifulSoup\u662f\u6700\u5e38\u7528\u7684\u7ec4\u5408\uff0c\u56e0\u4e3a\u5b83\u4eec\u7b80\u5355\u6613\u7528\u4e14\u529f\u80fd\u5f3a\u5927\u3002<\/p>\n<\/p>\n<ol>\n<li><strong>requests\u5e93<\/strong>\uff1a\u7528\u4e8e\u53d1\u9001HTTP\u8bf7\u6c42\u3002\u5b83\u53ef\u4ee5\u8f7b\u677e\u5730\u83b7\u53d6\u7f51\u9875\u7684HTML\u5185\u5bb9\u3002<\/li>\n<li><strong>BeautifulSoup\u5e93<\/strong>\uff1a\u7528\u4e8e\u89e3\u6790HTML\u548cXML\u6587\u6863\u3002\u5b83\u80fd\u591f\u65b9\u4fbf\u5730\u4eceHTML\u6587\u6863\u4e2d\u63d0\u53d6\u6570\u636e\u3002<\/li>\n<\/ol>\n<p><h4>\u5b89\u88c5requests\u548cBeautifulSoup<\/h4>\n<\/p>\n<p><p>\u5728\u4f7f\u7528\u8fd9\u4e9b\u5de5\u5177\u4e4b\u524d\uff0c\u9700\u8981\u5148\u5b89\u88c5\u5b83\u4eec\u3002\u53ef\u4ee5\u901a\u8fc7pip\u8fdb\u884c\u5b89\u88c5\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-bash\">pip install requests<\/p>\n<p>pip install beautifulsoup4<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h3>\u4e8c\u3001\u8bbe\u7f6e\u8bf7\u6c42\u5934\u6a21\u62df\u6d4f\u89c8\u5668\u8bbf\u95ee<\/h3>\n<\/p>\n<p><p>\u4e3a\u4e86\u907f\u514d\u88ab\u767e\u5ea6\u7684\u53cd\u722c\u866b\u673a\u5236\u8bc6\u522b\uff0c\u6211\u4eec\u9700\u8981\u5728\u53d1\u9001\u8bf7\u6c42\u65f6\u6a21\u62df\u6d4f\u89c8\u5668\u7684\u884c\u4e3a\u3002\u8fd9\u53ef\u4ee5\u901a\u8fc7\u8bbe\u7f6e\u8bf7\u6c42\u5934\uff08headers\uff09\u6765\u5b9e\u73b0\u3002<\/p>\n<\/p>\n<p><h4>\u8bbe\u7f6e\u8bf7\u6c42\u5934<\/h4>\n<\/p>\n<p><pre><code class=\"language-python\">import requests<\/p>\n<p>headers = {<\/p>\n<p>    &#39;User-Agent&#39;: &#39;Mozilla\/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/58.0.3029.110 Safari\/537.3&#39;}<\/p>\n<p>response = requests.get(&#39;https:\/\/www.b<a href=\"https:\/\/docs.pingcode.com\/blog\/59162.html\" target=\"_blank\">AI<\/a>du.com\/s?wd=Python&#39;, headers=headers)<\/p>\n<p>print(response.text)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5728\u4e0a\u9762\u7684\u4ee3\u7801\u4e2d\uff0c\u6211\u4eec\u8bbe\u7f6e\u4e86User-Agent\u5934\u90e8\u4fe1\u606f\uff0c\u4f7f\u5f97\u6211\u4eec\u7684\u8bf7\u6c42\u770b\u8d77\u6765\u50cf\u662f\u6765\u81ea\u4e00\u4e2a\u6b63\u5e38\u7684\u6d4f\u89c8\u5668\u3002<\/p>\n<\/p>\n<p><h3>\u4e09\u3001\u5904\u7406\u53cd\u722c\u673a\u5236<\/h3>\n<\/p>\n<p><p>\u767e\u5ea6\u6709\u4e00\u5957\u590d\u6742\u7684\u53cd\u722c\u866b\u673a\u5236\uff0c\u5305\u62ec\u4f46\u4e0d\u9650\u4e8eIP\u9650\u5236\u3001\u9a8c\u8bc1\u7801\u3001\u9875\u9762\u8df3\u8f6c\u7b49\u3002\u4e3a\u4e86\u6210\u529f\u6293\u53d6\u6570\u636e\uff0c\u6211\u4eec\u9700\u8981\u91c7\u53d6\u4e00\u4e9b\u63aa\u65bd\u6765\u7ed5\u8fc7\u8fd9\u4e9b\u673a\u5236\u3002<\/p>\n<\/p>\n<p><h4>\u4f7f\u7528\u4ee3\u7406IP<\/h4>\n<\/p>\n<p><p>\u901a\u8fc7\u4f7f\u7528\u4ee3\u7406IP\uff0c\u53ef\u4ee5\u5728\u4e00\u5b9a\u7a0b\u5ea6\u4e0a\u907f\u514d\u88ab\u767e\u5ea6\u5c01\u7981\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">proxies = {<\/p>\n<p>    &#39;http&#39;: &#39;http:\/\/10.10.1.10:3128&#39;,<\/p>\n<p>    &#39;https&#39;: &#39;http:\/\/10.10.1.10:1080&#39;,<\/p>\n<p>}<\/p>\n<p>response = requests.get(&#39;https:\/\/www.baidu.com\/s?wd=Python&#39;, headers=headers, proxies=proxies)<\/p>\n<p>print(response.text)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>\u8bbe\u7f6e\u8bf7\u6c42\u95f4\u9694<\/h4>\n<\/p>\n<p><p>\u4e3a\u4e86\u907f\u514d\u9891\u7e41\u8bf7\u6c42\u5bfc\u81f4\u88ab\u5c01\u7981\uff0c\u6211\u4eec\u9700\u8981\u8bbe\u7f6e\u5408\u7406\u7684\u8bf7\u6c42\u95f4\u9694\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import time<\/p>\n<p>for i in range(10):<\/p>\n<p>    response = requests.get(f&#39;https:\/\/www.baidu.com\/s?wd=Python&amp;page={i}&#39;, headers=headers)<\/p>\n<p>    print(response.text)<\/p>\n<p>    time.sleep(2)  # \u6bcf\u6b21\u8bf7\u6c42\u95f4\u96942\u79d2<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h3>\u56db\u3001\u89e3\u6790\u7f51\u9875\u5185\u5bb9<\/h3>\n<\/p>\n<p><p>\u83b7\u53d6\u5230\u7f51\u9875\u5185\u5bb9\u540e\uff0c\u6211\u4eec\u9700\u8981\u4f7f\u7528BeautifulSoup\u6765\u89e3\u6790HTML\u6587\u6863\uff0c\u5e76\u63d0\u53d6\u6211\u4eec\u9700\u8981\u7684\u6570\u636e\u3002<\/p>\n<\/p>\n<p><h4>\u4f7f\u7528BeautifulSoup\u89e3\u6790HTML<\/h4>\n<\/p>\n<p><pre><code class=\"language-python\">from bs4 import BeautifulSoup<\/p>\n<p>soup = BeautifulSoup(response.text, &#39;html.parser&#39;)<\/p>\n<p>titles = soup.find_all(&#39;h3&#39;, class_=&#39;t&#39;)<\/p>\n<p>for title in titles:<\/p>\n<p>    print(title.get_text())<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5728\u4e0a\u9762\u7684\u4ee3\u7801\u4e2d\uff0c\u6211\u4eec\u901a\u8fc7BeautifulSoup\u89e3\u6790HTML\uff0c\u5e76\u63d0\u53d6\u6240\u6709\u6807\u9898\u4e3ah3\u4e14class\u4e3at\u7684\u5185\u5bb9\u3002<\/p>\n<\/p>\n<p><h3>\u4e94\u3001\u5b58\u50a8\u6293\u53d6\u7684\u6570\u636e<\/h3>\n<\/p>\n<p><p>\u6293\u53d6\u5230\u7684\u6570\u636e\u9700\u8981\u8fdb\u884c\u5b58\u50a8\uff0c\u4ee5\u4fbf\u540e\u7eed\u5904\u7406\u3002\u53ef\u4ee5\u5c06\u6570\u636e\u5b58\u50a8\u5728\u672c\u5730\u6587\u4ef6\u3001\u6570\u636e\u5e93\u6216\u4e91\u5b58\u50a8\u4e2d\u3002<\/p>\n<\/p>\n<p><h4>\u5c06\u6570\u636e\u5b58\u50a8\u5728\u672c\u5730\u6587\u4ef6<\/h4>\n<\/p>\n<p><pre><code class=\"language-python\">with open(&#39;data.txt&#39;, &#39;w&#39;, encoding=&#39;utf-8&#39;) as f:<\/p>\n<p>    for title in titles:<\/p>\n<p>        f.write(title.get_text() + &#39;\\n&#39;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h3>\u516d\u3001\u5904\u7406\u52a8\u6001\u52a0\u8f7d\u5185\u5bb9<\/h3>\n<\/p>\n<p><p>\u6709\u65f6\u5019\u7f51\u9875\u5185\u5bb9\u662f\u901a\u8fc7JavaScript\u52a8\u6001\u52a0\u8f7d\u7684\uff0c\u8fd9\u79cd\u60c5\u51b5\u4e0b\uff0crequests\u548cBeautifulSoup\u65e0\u6cd5\u76f4\u63a5\u83b7\u53d6\u5230\u9700\u8981\u7684\u6570\u636e\u3002\u53ef\u4ee5\u4f7f\u7528Selenium\u7b49\u5de5\u5177\u6765\u5904\u7406\u52a8\u6001\u52a0\u8f7d\u5185\u5bb9\u3002<\/p>\n<\/p>\n<p><h4>\u4f7f\u7528Selenium\u5904\u7406\u52a8\u6001\u52a0\u8f7d\u5185\u5bb9<\/h4>\n<\/p>\n<p><p>\u9996\u5148\uff0c\u9700\u8981\u5b89\u88c5Selenium\u548c\u6d4f\u89c8\u5668\u9a71\u52a8\uff08\u5982ChromeDriver\uff09\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-bash\">pip install selenium<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u7136\u540e\uff0c\u901a\u8fc7Selenium\u6a21\u62df\u6d4f\u89c8\u5668\u8bbf\u95ee\u5e76\u6293\u53d6\u52a8\u6001\u52a0\u8f7d\u7684\u5185\u5bb9\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">from selenium import webdriver<\/p>\n<p>options = webdriver.ChromeOptions()<\/p>\n<p>options.add_argument(&#39;--headless&#39;)<\/p>\n<p>driver = webdriver.Chrome(options=options)<\/p>\n<p>driver.get(&#39;https:\/\/www.baidu.com\/s?wd=Python&#39;)<\/p>\n<p>page_source = driver.page_source<\/p>\n<p>soup = BeautifulSoup(page_source, &#39;html.parser&#39;)<\/p>\n<p>titles = soup.find_all(&#39;h3&#39;, class_=&#39;t&#39;)<\/p>\n<p>for title in titles:<\/p>\n<p>    print(title.get_text())<\/p>\n<p>driver.quit()<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5728\u4e0a\u9762\u7684\u4ee3\u7801\u4e2d\uff0c\u6211\u4eec\u4f7f\u7528Selenium\u6a21\u62df\u6d4f\u89c8\u5668\u8bbf\u95ee\u767e\u5ea6\u641c\u7d22\u9875\u9762\uff0c\u5e76\u901a\u8fc7BeautifulSoup\u89e3\u6790\u52a8\u6001\u52a0\u8f7d\u7684\u5185\u5bb9\u3002<\/p>\n<\/p>\n<p><h3>\u4e03\u3001\u5904\u7406\u9a8c\u8bc1\u7801<\/h3>\n<\/p>\n<p><p>\u5728\u6293\u53d6\u6570\u636e\u7684\u8fc7\u7a0b\u4e2d\uff0c\u6709\u65f6\u4f1a\u9047\u5230\u9a8c\u8bc1\u7801\u3002\u53ef\u4ee5\u901a\u8fc7\u624b\u52a8\u8f93\u5165\u9a8c\u8bc1\u7801\u6216\u4f7f\u7528\u56fe\u50cf\u8bc6\u522b\u6280\u672f\u6765\u89e3\u51b3\u8fd9\u4e2a\u95ee\u9898\u3002<\/p>\n<\/p>\n<p><h4>\u624b\u52a8\u8f93\u5165\u9a8c\u8bc1\u7801<\/h4>\n<\/p>\n<p><p>\u5f53\u9047\u5230\u9a8c\u8bc1\u7801\u65f6\uff0c\u53ef\u4ee5\u6682\u505c\u7a0b\u5e8f\u8fd0\u884c\uff0c\u7b49\u5f85\u7528\u6237\u624b\u52a8\u8f93\u5165\u9a8c\u8bc1\u7801\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">input(&quot;Please enter the captcha and press Enter to continue...&quot;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>\u4f7f\u7528\u56fe\u50cf\u8bc6\u522b\u6280\u672f<\/h4>\n<\/p>\n<p><p>\u53ef\u4ee5\u4f7f\u7528\u4e00\u4e9b\u56fe\u50cf\u8bc6\u522b\u5e93\uff08\u5982Tesseract\uff09\u6765\u81ea\u52a8\u8bc6\u522b\u9a8c\u8bc1\u7801\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-bash\">pip install pytesseract<\/p>\n<p>pip install pillow<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><pre><code class=\"language-python\">from PIL import Image<\/p>\n<p>import pytesseract<\/p>\n<p>captcha_image = Image.open(&#39;captcha.png&#39;)<\/p>\n<p>captcha_text = pytesseract.image_to_string(captcha_image)<\/p>\n<p>print(captcha_text)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h3>\u516b\u3001\u603b\u7ed3<\/h3>\n<\/p>\n<p><p>\u4f7f\u7528Python\u6293\u53d6\u767e\u5ea6\u641c\u7d22\u6570\u636e\u662f\u4e00\u9879\u590d\u6742\u4f46\u975e\u5e38\u6709\u7528\u7684\u6280\u80fd\u3002\u901a\u8fc7\u9009\u62e9\u5408\u9002\u7684\u722c\u866b\u5de5\u5177\u3001\u8bbe\u7f6e\u8bf7\u6c42\u5934\u6a21\u62df\u6d4f\u89c8\u5668\u8bbf\u95ee\u3001\u5904\u7406\u53cd\u722c\u673a\u5236\u3001\u89e3\u6790\u7f51\u9875\u5185\u5bb9\u7b49\u6b65\u9aa4\uff0c\u6211\u4eec\u53ef\u4ee5\u6709\u6548\u5730\u6293\u53d6\u5230\u6240\u9700\u7684\u6570\u636e\u3002\u540c\u65f6\uff0c\u8fd8\u9700\u8981\u5904\u7406\u4e00\u4e9b\u7279\u6b8a\u60c5\u51b5\uff0c\u5982\u52a8\u6001\u52a0\u8f7d\u5185\u5bb9\u548c\u9a8c\u8bc1\u7801\u3002\u901a\u8fc7\u4e0d\u65ad\u5b9e\u8df5\u548c\u4f18\u5316\uff0c\u53ef\u4ee5\u63d0\u9ad8\u6293\u53d6\u6548\u7387\u548c\u6570\u636e\u8d28\u91cf\u3002<\/p>\n<\/p>\n<p><p>\u603b\u4e4b\uff0c\u6293\u53d6\u767e\u5ea6\u641c\u7d22\u6570\u636e\u9700\u8981\u7efc\u5408\u8fd0\u7528\u5404\u79cd\u6280\u672f\u624b\u6bb5\uff0c\u5e76\u6839\u636e\u5177\u4f53\u60c5\u51b5\u8fdb\u884c\u8c03\u6574\u548c\u4f18\u5316\u3002\u5e0c\u671b\u672c\u6587\u80fd\u591f\u4e3a\u8bfb\u8005\u63d0\u4f9b\u4e00\u4e9b\u6709\u7528\u7684\u53c2\u8003\u548c\u6307\u5bfc\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p> <strong>\u5982\u4f55\u4f7f\u7528Python\u6293\u53d6\u767e\u5ea6\u641c\u7d22\u7ed3\u679c\u7684\u57fa\u672c\u6b65\u9aa4\u662f\u4ec0\u4e48\uff1f<\/strong><br \/>\u6293\u53d6\u767e\u5ea6\u641c\u7d22\u6570\u636e\u901a\u5e38\u6d89\u53ca\u51e0\u4e2a\u5173\u952e\u6b65\u9aa4\u3002\u9996\u5148\uff0c\u60a8\u9700\u8981\u5b89\u88c5Python\u548c\u76f8\u5173\u5e93\uff0c\u5982Requests\u548cBeautifulSoup\u3002\u63a5\u4e0b\u6765\uff0c\u6784\u9020\u9002\u5f53\u7684URL\u4ee5\u6267\u884c\u641c\u7d22\uff0c\u5e76\u53d1\u9001HTTP\u8bf7\u6c42\u6765\u83b7\u53d6\u9875\u9762\u5185\u5bb9\u3002\u7136\u540e\uff0c\u4f7f\u7528BeautifulSoup\u89e3\u6790HTML\u6587\u6863\uff0c\u63d0\u53d6\u6240\u9700\u7684\u4fe1\u606f\uff0c\u5982\u6807\u9898\u3001\u94fe\u63a5\u548c\u6458\u8981\u3002\u6700\u540e\uff0c\u60a8\u53ef\u4ee5\u5c06\u6293\u53d6\u7684\u6570\u636e\u5b58\u50a8\u5728CSV\u6587\u4ef6\u6216\u6570\u636e\u5e93\u4e2d\uff0c\u4ee5\u4fbf\u540e\u7eed\u5206\u6790\u3002<\/p>\n<p><strong>\u5728\u6293\u53d6\u767e\u5ea6\u6570\u636e\u65f6\uff0c\u5982\u4f55\u5904\u7406\u53cd\u722c\u866b\u673a\u5236\uff1f<\/strong><br \/>\u767e\u5ea6\u7b49\u641c\u7d22\u5f15\u64ce\u901a\u5e38\u4f1a\u5b9e\u65bd\u53cd\u722c\u866b\u63aa\u65bd\uff0c\u4ee5\u9632\u6b62\u6076\u610f\u6293\u53d6\u3002\u4e3a\u4e86\u907f\u514d\u88ab\u5c01\u7981\uff0c\u53ef\u4ee5\u91c7\u53d6\u51e0\u79cd\u7b56\u7565\u3002\u4f8b\u5982\uff0c\u4f7f\u7528\u968f\u673a\u7684User-Agent\u5b57\u7b26\u4e32\u6765\u6a21\u62df\u4e0d\u540c\u7684\u6d4f\u89c8\u5668\u8bf7\u6c42\uff0c\u6216\u8005\u8bbe\u7f6e\u8bf7\u6c42\u95f4\u9694\uff0c\u4ee5\u51cf\u5c11\u5bf9\u670d\u52a1\u5668\u7684\u538b\u529b\u3002\u6b64\u5916\uff0c\u53ef\u4ee5\u4f7f\u7528\u4ee3\u7406IP\u8fdb\u884c\u8bf7\u6c42\uff0c\u4ee5\u964d\u4f4e\u88ab\u68c0\u6d4b\u7684\u98ce\u9669\u3002\u5408\u7406\u8bbe\u7f6e\u6293\u53d6\u9891\u7387\u4e5f\u662f\u4fdd\u62a4\u81ea\u5df1\u4e0d\u88ab\u5c01\u7981\u7684\u91cd\u8981\u63aa\u65bd\u3002<\/p>\n<p><strong>\u6293\u53d6\u7684\u6570\u636e\u5982\u4f55\u8fdb\u884c\u5206\u6790\u548c\u53ef\u89c6\u5316\uff1f<\/strong><br \/>\u83b7\u53d6\u5230\u767e\u5ea6\u641c\u7d22\u6570\u636e\u540e\uff0c\u60a8\u53ef\u4ee5\u4f7f\u7528Pandas\u5e93\u5bf9\u6570\u636e\u8fdb\u884c\u6e05\u6d17\u548c\u5904\u7406\u3002\u5206\u6790\u65f6\uff0c\u53ef\u4ee5\u8ba1\u7b97\u5173\u952e\u8bcd\u7684\u51fa\u73b0\u9891\u7387\u3001\u8d8b\u52bf\u53d8\u5316\u7b49\u3002\u5bf9\u4e8e\u53ef\u89c6\u5316\uff0c\u53ef\u4ee5\u5229\u7528Matplotlib\u6216Seaborn\u7b49\u5e93\u751f\u6210\u56fe\u8868\uff0c\u5c55\u793a\u641c\u7d22\u7ed3\u679c\u7684\u5206\u5e03\u6216\u5176\u4ed6\u6709\u8da3\u7684\u6a21\u5f0f\u3002\u8fd9\u4e9b\u5206\u6790\u7ed3\u679c\u53ef\u4ee5\u5e2e\u52a9\u60a8\u66f4\u597d\u5730\u7406\u89e3\u7528\u6237\u9700\u6c42\u548c\u5e02\u573a\u8d8b\u52bf\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"\u5982\u4f55\u7528Python\u6293\u53d6\u767e\u5ea6\u641c\u7d22\u6570\u636e \u4f7f\u7528Python\u6293\u53d6\u767e\u5ea6\u641c\u7d22\u6570\u636e\u7684\u6838\u5fc3\u6b65\u9aa4\u5305\u62ec\uff1a\u9009\u62e9\u5408\u9002\u7684\u722c\u866b\u5de5\u5177\u3001\u8bbe\u7f6e\u8bf7 [&hellip;]","protected":false},"author":3,"featured_media":1131858,"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\/1131849"}],"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=1131849"}],"version-history":[{"count":"1","href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1131849\/revisions"}],"predecessor-version":[{"id":1131861,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1131849\/revisions\/1131861"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/1131858"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=1131849"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=1131849"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=1131849"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}