{"id":961354,"date":"2024-12-27T03:57:56","date_gmt":"2024-12-26T19:57:56","guid":{"rendered":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/961354.html"},"modified":"2024-12-27T03:57:58","modified_gmt":"2024-12-26T19:57:58","slug":"python%e5%a6%82%e4%bd%95%e9%85%8d%e7%bd%ae%e5%88%b0%e9%9b%86%e7%be%a4","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/961354.html","title":{"rendered":"python\u5982\u4f55\u914d\u7f6e\u5230\u96c6\u7fa4"},"content":{"rendered":"<p style=\"text-align:center;\" ><img decoding=\"async\" src=\"https:\/\/cdn-kb.worktile.com\/kb\/wp-content\/uploads\/2024\/04\/25103621\/aa42fca0-e9ed-4335-99ed-c547217121e7.webp\" alt=\"python\u5982\u4f55\u914d\u7f6e\u5230\u96c6\u7fa4\" \/><\/p>\n<p><p> <strong>\u914d\u7f6ePython\u5230\u96c6\u7fa4\u7684\u65b9\u6cd5\u5305\u62ec\uff1a\u5b89\u88c5Python\u73af\u5883\u3001\u914d\u7f6e\u865a\u62df\u73af\u5883\u3001\u8bbe\u7f6e\u96c6\u7fa4\u7ba1\u7406\u5de5\u5177\u3001\u5206\u53d1\u4ee3\u7801\u5230\u5404\u4e2a\u8282\u70b9\u3001\u4f7f\u7528\u5e76\u884c\u8ba1\u7b97\u5e93\u3001\u76d1\u63a7\u548c\u8c03\u8bd5\u96c6\u7fa4\u4efb\u52a1\u3002<\/strong>\u5b89\u88c5Python\u73af\u5883\u662f\u57fa\u7840\u6b65\u9aa4\uff0c\u786e\u4fdd\u6240\u6709\u8282\u70b9\u4e0a\u6709\u4e00\u81f4\u7684Python\u7248\u672c\u548c\u6240\u9700\u5e93\u3002\u63a5\u4e0b\u6765\uff0c\u4f7f\u7528\u865a\u62df\u73af\u5883\u6765\u9694\u79bb\u9879\u76ee\u4f9d\u8d56\uff0c\u907f\u514d\u7248\u672c\u51b2\u7a81\u3002\u4e3a\u4e86\u7ba1\u7406\u548c\u8c03\u5ea6\u4efb\u52a1\uff0c\u96c6\u7fa4\u7ba1\u7406\u5de5\u5177\uff08\u5982Slurm\u3001Hadoop\u6216Kubernetes\uff09\u662f\u4e0d\u53ef\u6216\u7f3a\u7684\u3002\u4ee3\u7801\u9700\u8981\u5206\u53d1\u5230\u5404\u4e2a\u8282\u70b9\uff0c\u53ef\u4ee5\u4f7f\u7528\u5171\u4eab\u6587\u4ef6\u7cfb\u7edf\u6216\u81ea\u52a8\u5316\u811a\u672c\u3002\u5e76\u884c\u8ba1\u7b97\u5e93\uff08\u5982Dask\u3001MPI4Py\uff09\u5c06\u5e2e\u52a9\u4f60\u5145\u5206\u5229\u7528\u96c6\u7fa4\u7684\u8ba1\u7b97\u80fd\u529b\u3002\u6700\u540e\uff0c\u76d1\u63a7\u548c\u8c03\u8bd5\u96c6\u7fa4\u4efb\u52a1\u662f\u786e\u4fdd\u4efb\u52a1\u6b63\u5e38\u8fd0\u884c\u7684\u5173\u952e\u3002<\/p>\n<\/p>\n<p><p>\u4e00\u3001\u5b89\u88c5Python\u73af\u5883<\/p>\n<\/p>\n<p><p>\u5728\u96c6\u7fa4\u4e0a\u5b89\u88c5Python\u662f\u8fdb\u884c\u5206\u5e03\u5f0f\u8ba1\u7b97\u7684\u7b2c\u4e00\u6b65\u3002\u901a\u5e38\uff0c\u96c6\u7fa4\u4e0a\u7684\u6bcf\u4e2a\u8282\u70b9\u90fd\u9700\u8981\u6709\u76f8\u540c\u7684Python\u7248\u672c\u4ee5\u53ca\u4e00\u81f4\u7684\u5e93\u73af\u5883\u3002\u8fd9\u53ef\u4ee5\u901a\u8fc7\u4ee5\u4e0b\u51e0\u79cd\u65b9\u5f0f\u5b9e\u73b0\uff1a<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>\u4f7f\u7528\u7cfb\u7edf\u5305\u7ba1\u7406\u5668<\/strong>\uff1a\u5728Linux\u7cfb\u7edf\u4e0a\uff0c\u53ef\u4ee5\u4f7f\u7528apt\u3001yum\u7b49\u5305\u7ba1\u7406\u5668\u6765\u5b89\u88c5Python\u3002\u4f8b\u5982\uff0c\u5728Ubuntu\u4e0a\uff0c\u53ef\u4ee5\u4f7f\u7528<code>sudo apt-get install python3<\/code>\u6765\u5b89\u88c5Python 3\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u4f7f\u7528Anaconda<\/strong>\uff1aAnaconda\u662f\u4e00\u4e2a\u5e38\u7528\u7684\u6570\u636e\u79d1\u5b66\u5e73\u53f0\uff0c\u63d0\u4f9b\u4e86Python\u548c\u5927\u91cf\u79d1\u5b66\u8ba1\u7b97\u5e93\u7684\u6253\u5305\u3002\u53ef\u4ee5\u4e0b\u8f7dAnaconda\u5b89\u88c5\u5305\uff0c\u5e76\u5728\u96c6\u7fa4\u7684\u6bcf\u4e2a\u8282\u70b9\u4e0a\u5b89\u88c5\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u624b\u52a8\u7f16\u8bd1\u5b89\u88c5<\/strong>\uff1a\u5bf9\u4e8e\u9700\u8981\u7279\u5b9aPython\u7248\u672c\u6216\u81ea\u5b9a\u4e49\u5b89\u88c5\u8def\u5f84\u7684\u60c5\u51b5\uff0c\u53ef\u4ee5\u4ecePython\u7684\u5b98\u65b9\u7f51\u7ad9\u4e0b\u8f7d\u6e90\u7801\u5e76\u81ea\u884c\u7f16\u8bd1\u5b89\u88c5\u3002\u8fd9\u79cd\u65b9\u6cd5\u7075\u6d3b\u4f46\u590d\u6742\uff0c\u9700\u8981\u786e\u4fdd\u6240\u6709\u4f9d\u8d56\u5e93\u5728\u6bcf\u4e2a\u8282\u70b9\u4e0a\u90fd\u5df2\u5b89\u88c5\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u4e8c\u3001\u914d\u7f6e\u865a\u62df\u73af\u5883<\/p>\n<\/p>\n<p><p>\u914d\u7f6e\u865a\u62df\u73af\u5883\u53ef\u4ee5\u6709\u6548\u9694\u79bb\u9879\u76ee\u7684\u4f9d\u8d56\uff0c\u907f\u514d\u4e0d\u540c\u9879\u76ee\u4e4b\u95f4\u7684\u5e93\u7248\u672c\u51b2\u7a81\u3002\u4ee5\u4e0b\u662f\u5e38\u7528\u7684\u865a\u62df\u73af\u5883\u7ba1\u7406\u5de5\u5177\uff1a<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>venv<\/strong>\uff1aPython\u5185\u7f6e\u7684\u865a\u62df\u73af\u5883\u6a21\u5757\uff0c\u4f7f\u7528\u7b80\u5355\uff0c\u9002\u7528\u4e8e\u5927\u591a\u6570\u60c5\u51b5\u3002\u53ef\u4ee5\u5728\u9879\u76ee\u76ee\u5f55\u4e0b\u4f7f\u7528<code>python3 -m venv myenv<\/code>\u521b\u5efa\u865a\u62df\u73af\u5883\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>virtualenv<\/strong>\uff1a\u529f\u80fd\u66f4\u5f3a\u5927\u7684\u865a\u62df\u73af\u5883\u5de5\u5177\uff0c\u652f\u6301Python 2\u548cPython 3\u3002\u53ef\u4ee5\u4f7f\u7528<code>pip install virtualenv<\/code>\u5b89\u88c5\uff0c\u7136\u540e\u7528<code>virtualenv myenv<\/code>\u547d\u4ee4\u521b\u5efa\u865a\u62df\u73af\u5883\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>conda<\/strong>\uff1aAnaconda\u63d0\u4f9b\u7684\u73af\u5883\u7ba1\u7406\u5de5\u5177\uff0c\u652f\u6301\u521b\u5efa\u865a\u62df\u73af\u5883\u5e76\u7ba1\u7406\u5176\u4f9d\u8d56\u3002\u53ef\u4ee5\u4f7f\u7528<code>conda create -n myenv python=3.8<\/code>\u521b\u5efa\u6307\u5b9aPython\u7248\u672c\u7684\u865a\u62df\u73af\u5883\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u4e09\u3001\u8bbe\u7f6e\u96c6\u7fa4\u7ba1\u7406\u5de5\u5177<\/p>\n<\/p>\n<p><p>\u4e3a\u4e86\u9ad8\u6548\u5730\u7ba1\u7406\u548c\u8c03\u5ea6\u96c6\u7fa4\u4efb\u52a1\uff0c\u4f7f\u7528\u5408\u9002\u7684\u96c6\u7fa4\u7ba1\u7406\u5de5\u5177\u662f\u5fc5\u4e0d\u53ef\u5c11\u7684\u3002\u4ee5\u4e0b\u662f\u51e0\u79cd\u5e38\u7528\u7684\u5de5\u5177\uff1a<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>Slurm<\/strong>\uff1a\u4e00\u79cd\u5f00\u6e90\u7684\u96c6\u7fa4\u7ba1\u7406\u548c\u8c03\u5ea6\u7cfb\u7edf\uff0c\u5e7f\u6cdb\u5e94\u7528\u4e8e\u9ad8\u6027\u80fd\u8ba1\u7b97\u96c6\u7fa4\u3002Slurm\u901a\u8fc7\u4f5c\u4e1a\u811a\u672c\u63d0\u4ea4\u4efb\u52a1\uff0c\u652f\u6301\u8d44\u6e90\u5206\u914d\u3001\u4efb\u52a1\u5e76\u884c\u548c\u8d1f\u8f7d\u5747\u8861\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>Hadoop<\/strong>\uff1a\u7528\u4e8e\u5927\u6570\u636e\u5904\u7406\u7684\u5206\u5e03\u5f0f\u6846\u67b6\uff0c\u9002\u5408\u5904\u7406\u6d77\u91cf\u6570\u636e\u7684\u6279\u5904\u7406\u4efb\u52a1\u3002Hadoop\u751f\u6001\u7cfb\u7edf\u4e2d\u5305\u542bHDFS\u3001MapReduce\u7b49\u7ec4\u4ef6\uff0c\u9002\u5408\u5927\u89c4\u6a21\u6570\u636e\u5206\u6790\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>Kubernetes<\/strong>\uff1a\u4e00\u79cd\u5bb9\u5668\u7f16\u6392\u5e73\u53f0\uff0c\u9002\u5408\u7ba1\u7406\u5bb9\u5668\u5316\u5e94\u7528\u7684\u5206\u5e03\u5f0f\u90e8\u7f72\u548c\u8fd0\u884c\u3002Kubernetes\u652f\u6301\u81ea\u52a8\u6269\u5c55\u3001\u8d1f\u8f7d\u5747\u8861\u548c\u6545\u969c\u6062\u590d\uff0c\u662f\u73b0\u4ee3\u4e91\u8ba1\u7b97\u73af\u5883\u7684\u4e3b\u6d41\u9009\u62e9\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u56db\u3001\u5206\u53d1\u4ee3\u7801\u5230\u5404\u4e2a\u8282\u70b9<\/p>\n<\/p>\n<p><p>\u4e3a\u4e86\u5728\u96c6\u7fa4\u4e2d\u8fd0\u884cPython\u4ee3\u7801\uff0c\u9700\u8981\u5c06\u4ee3\u7801\u5206\u53d1\u5230\u5404\u4e2a\u8ba1\u7b97\u8282\u70b9\u3002\u4ee5\u4e0b\u662f\u51e0\u79cd\u5e38\u7528\u7684\u65b9\u6cd5\uff1a<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>\u5171\u4eab\u6587\u4ef6\u7cfb\u7edf<\/strong>\uff1a\u5728\u96c6\u7fa4\u4e2d\u4f7f\u7528NFS\u3001GlusterFS\u7b49\u5171\u4eab\u6587\u4ef6\u7cfb\u7edf\uff0c\u4f7f\u6240\u6709\u8282\u70b9\u53ef\u4ee5\u8bbf\u95ee\u540c\u4e00\u4efd\u4ee3\u7801\u548c\u6570\u636e\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u7248\u672c\u63a7\u5236\u7cfb\u7edf<\/strong>\uff1a\u4f7f\u7528Git\u7b49\u7248\u672c\u63a7\u5236\u7cfb\u7edf\uff0c\u5c06\u4ee3\u7801\u4ed3\u5e93\u514b\u9686\u5230\u6bcf\u4e2a\u8282\u70b9\u3002\u8fd9\u79cd\u65b9\u6cd5\u9002\u5408\u56e2\u961f\u534f\u4f5c\u548c\u4ee3\u7801\u7ba1\u7406\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u81ea\u52a8\u5316\u811a\u672c<\/strong>\uff1a\u7f16\u5199\u81ea\u52a8\u5316\u811a\u672c\uff0c\u4f7f\u7528scp\u6216rsync\u7b49\u5de5\u5177\uff0c\u5c06\u4ee3\u7801\u5206\u53d1\u5230\u5404\u4e2a\u8282\u70b9\u3002\u8fd9\u79cd\u65b9\u6cd5\u7075\u6d3b\u4e14\u9002\u5408\u4e0d\u540c\u89c4\u6a21\u7684\u96c6\u7fa4\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u4e94\u3001\u4f7f\u7528\u5e76\u884c\u8ba1\u7b97\u5e93<\/p>\n<\/p>\n<p><p>\u4e3a\u4e86\u5145\u5206\u5229\u7528\u96c6\u7fa4\u7684\u8ba1\u7b97\u80fd\u529b\uff0c\u4f7f\u7528\u5e76\u884c\u8ba1\u7b97\u5e93\u662f\u5173\u952e\u3002\u8fd9\u4e9b\u5e93\u53ef\u4ee5\u5e2e\u52a9\u4f60\u5c06\u4efb\u52a1\u62c6\u5206\u4e3a\u591a\u4e2a\u5e76\u884c\u6267\u884c\u7684\u5b50\u4efb\u52a1\uff1a<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>Dask<\/strong>\uff1a\u4e00\u4e2a\u7075\u6d3b\u7684\u5e76\u884c\u8ba1\u7b97\u5e93\uff0c\u652f\u6301\u5927\u89c4\u6a21\u6570\u636e\u5904\u7406\u548c<a href=\"https:\/\/docs.pingcode.com\/ask\/59192.html\" target=\"_blank\">\u673a\u5668\u5b66\u4e60<\/a>\u4efb\u52a1\u3002Dask\u63d0\u4f9b\u4e0eNumPy\u3001Pandas\u517c\u5bb9\u7684API\uff0c\u4fbf\u4e8e\u73b0\u6709\u4ee3\u7801\u7684\u8fc1\u79fb\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>MPI4Py<\/strong>\uff1aMPI\u7684Python\u63a5\u53e3\uff0c\u9002\u5408\u9ad8\u6027\u80fd\u8ba1\u7b97\u4e2d\u7684\u6d88\u606f\u4f20\u9012\u6a21\u578b\u3002MPI4Py\u652f\u6301\u8fdb\u7a0b\u95f4\u901a\u4fe1\u548c\u540c\u6b65\uff0c\u9002\u7528\u4e8e\u9700\u8981\u7cbe\u7ec6\u63a7\u5236\u7684\u5e76\u884c\u4efb\u52a1\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>Ray<\/strong>\uff1a\u4e00\u4e2a\u7528\u4e8e\u5206\u5e03\u5f0f\u8ba1\u7b97\u7684\u6846\u67b6\uff0c\u652f\u6301\u4efb\u52a1\u5e76\u884c\u548c\u5206\u5e03\u5f0f\u6570\u636e\u5904\u7406\u3002Ray\u9002\u5408\u6784\u5efa\u5927\u89c4\u6a21\u7684\u5206\u5e03\u5f0f\u5e94\u7528\uff0c\u5982\u5f3a\u5316\u5b66\u4e60\u548c\u5927\u6570\u636e\u5206\u6790\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u516d\u3001\u76d1\u63a7\u548c\u8c03\u8bd5\u96c6\u7fa4\u4efb\u52a1<\/p>\n<\/p>\n<p><p>\u5728\u96c6\u7fa4\u4e2d\u8fd0\u884c\u4efb\u52a1\u65f6\uff0c\u76d1\u63a7\u548c\u8c03\u8bd5\u662f\u786e\u4fdd\u4efb\u52a1\u6b63\u5e38\u8fd0\u884c\u7684\u91cd\u8981\u6b65\u9aa4\u3002\u4ee5\u4e0b\u662f\u4e00\u4e9b\u5e38\u7528\u7684\u65b9\u6cd5\u548c\u5de5\u5177\uff1a<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>\u65e5\u5fd7\u8bb0\u5f55<\/strong>\uff1a\u5728\u4ee3\u7801\u4e2d\u6dfb\u52a0\u65e5\u5fd7\u8bb0\u5f55\uff0c\u5e2e\u52a9\u8ddf\u8e2a\u4efb\u52a1\u7684\u6267\u884c\u8fc7\u7a0b\u548c\u6355\u83b7\u6f5c\u5728\u7684\u9519\u8bef\u3002\u53ef\u4ee5\u4f7f\u7528Python\u7684logging\u6a21\u5757\u6216\u5176\u4ed6\u65e5\u5fd7\u5e93\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u76d1\u63a7\u5de5\u5177<\/strong>\uff1a\u4f7f\u7528\u96c6\u7fa4\u7ba1\u7406\u5de5\u5177\u63d0\u4f9b\u7684\u76d1\u63a7\u529f\u80fd\uff0c\u5b9e\u65f6\u67e5\u770b\u4efb\u52a1\u7684\u72b6\u6001\u3001\u8d44\u6e90\u4f7f\u7528\u60c5\u51b5\u548c\u6027\u80fd\u6307\u6807\u3002\u4f8b\u5982\uff0cSlurm\u63d0\u4f9bsacct\u547d\u4ee4\u67e5\u770b\u4efb\u52a1\u5386\u53f2\u8bb0\u5f55\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u8c03\u8bd5\u5de5\u5177<\/strong>\uff1a\u5728\u9700\u8981\u65f6\uff0c\u53ef\u4ee5\u4f7f\u7528Python\u8c03\u8bd5\u5668\uff08\u5982pdb\uff09\u8fdb\u884c\u8fdc\u7a0b\u8c03\u8bd5\uff0c\u6216\u5728\u4ee3\u7801\u4e2d\u8bbe\u7f6e\u65ad\u70b9\u8fdb\u884c\u95ee\u9898\u6392\u67e5\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u901a\u8fc7\u4ee5\u4e0a\u6b65\u9aa4\uff0c\u53ef\u4ee5\u6709\u6548\u5730\u914d\u7f6ePython\u5230\u96c6\u7fa4\u4e2d\uff0c\u5e76\u5229\u7528\u96c6\u7fa4\u7684\u8ba1\u7b97\u80fd\u529b\u8fdb\u884c\u5927\u89c4\u6a21\u7684\u6570\u636e\u5904\u7406\u548c\u79d1\u5b66\u8ba1\u7b97\u3002\u65e0\u8bba\u662f\u9ad8\u6027\u80fd\u8ba1\u7b97\u8fd8\u662f\u5927\u6570\u636e\u5206\u6790\uff0c\u5408\u7406\u7684\u914d\u7f6e\u548c\u7ba1\u7406\u90fd\u662f\u6210\u529f\u7684\u5173\u952e\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p> <strong>\u5982\u4f55\u5c06Python\u73af\u5883\u914d\u7f6e\u5230\u96c6\u7fa4\u4e2d\uff1f<\/strong><br \/>\u5728\u96c6\u7fa4\u4e2d\u914d\u7f6ePython\u73af\u5883\u901a\u5e38\u6d89\u53ca\u9009\u62e9\u5408\u9002\u7684\u5de5\u5177\u548c\u65b9\u6cd5\u3002\u5e38\u89c1\u7684\u505a\u6cd5\u662f\u4f7f\u7528Anaconda\u6216Virtualenv\u6765\u521b\u5efa\u4e00\u4e2a\u72ec\u7acb\u7684Python\u73af\u5883\uff0c\u7136\u540e\u5728\u6bcf\u4e2a\u8282\u70b9\u4e0a\u5b89\u88c5\u6240\u9700\u7684\u5e93\u548c\u4f9d\u8d56\u3002\u4f60\u8fd8\u53ef\u4ee5\u4f7f\u7528\u914d\u7f6e\u7ba1\u7406\u5de5\u5177\uff08\u5982Ansible\u6216Chef\uff09\u6765\u81ea\u52a8\u5316\u8fd9\u4e00\u8fc7\u7a0b\uff0c\u786e\u4fdd\u6240\u6709\u8282\u70b9\u90fd\u4fdd\u6301\u4e00\u81f4\u3002<\/p>\n<p><strong>\u5728\u96c6\u7fa4\u4e0a\u8fd0\u884cPython\u811a\u672c\u65f6\u9700\u8981\u6ce8\u610f\u54ea\u4e9b\u4e8b\u9879\uff1f<\/strong><br \/>\u5728\u96c6\u7fa4\u4e0a\u8fd0\u884cPython\u811a\u672c\u65f6\uff0c\u9700\u8981\u6ce8\u610f\u8d44\u6e90\u5206\u914d\u3001\u4f9d\u8d56\u7ba1\u7406\u548c\u9519\u8bef\u5904\u7406\u3002\u786e\u4fdd\u811a\u672c\u53ef\u4ee5\u5728\u4e0d\u540c\u7684\u8282\u70b9\u4e0a\u8fd0\u884c\u800c\u4e0d\u4f9d\u8d56\u4e8e\u7279\u5b9a\u7684\u73af\u5883\u914d\u7f6e\u3002\u6b64\u5916\uff0c\u4f7f\u7528\u9002\u5f53\u7684\u5e93\uff08\u5982Dask\u6216Spark\uff09\u53ef\u4ee5\u5e2e\u52a9\u5206\u5e03\u5f0f\u8ba1\u7b97\u548c\u6570\u636e\u5904\u7406\uff0c\u4ece\u800c\u63d0\u9ad8\u6548\u7387\u3002<\/p>\n<p><strong>\u5982\u4f55\u5728\u96c6\u7fa4\u4e2d\u7ba1\u7406Python\u5e93\u7684\u7248\u672c\uff1f<\/strong><br \/>\u7ba1\u7406Python\u5e93\u7248\u672c\u53ef\u4ee5\u901a\u8fc7\u4f7f\u7528requirements.txt\u6587\u4ef6\u6216Pipenv\u6765\u5b9e\u73b0\u3002\u786e\u4fdd\u5728\u96c6\u7fa4\u4e2d\u7684\u6bcf\u4e2a\u8282\u70b9\u4e0a\u90fd\u80fd\u901a\u8fc7\u8fd9\u4e9b\u5de5\u5177\u5b89\u88c5\u76f8\u540c\u7248\u672c\u7684\u5e93\u3002\u4f7f\u7528Docker\u5bb9\u5668\u4e5f\u662f\u4e00\u4e2a\u4e0d\u9519\u7684\u9009\u62e9\uff0c\u53ef\u4ee5\u786e\u4fdd\u5728\u4e0d\u540c\u73af\u5883\u4e2d\u8fd0\u884c\u76f8\u540c\u7684\u5e94\u7528\u7a0b\u5e8f\u548c\u4f9d\u8d56\u5173\u7cfb\uff0c\u907f\u514d\u7248\u672c\u51b2\u7a81\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"\u914d\u7f6ePython\u5230\u96c6\u7fa4\u7684\u65b9\u6cd5\u5305\u62ec\uff1a\u5b89\u88c5Python\u73af\u5883\u3001\u914d\u7f6e\u865a\u62df\u73af\u5883\u3001\u8bbe\u7f6e\u96c6\u7fa4\u7ba1\u7406\u5de5\u5177\u3001\u5206\u53d1\u4ee3\u7801\u5230\u5404\u4e2a\u8282\u70b9\u3001\u4f7f [&hellip;]","protected":false},"author":3,"featured_media":961359,"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\/961354"}],"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=961354"}],"version-history":[{"count":"1","href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/961354\/revisions"}],"predecessor-version":[{"id":961360,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/961354\/revisions\/961360"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/961359"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=961354"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=961354"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=961354"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}