{"id":1002683,"date":"2024-12-27T10:10:44","date_gmt":"2024-12-27T02:10:44","guid":{"rendered":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/1002683.html"},"modified":"2024-12-27T10:10:46","modified_gmt":"2024-12-27T02:10:46","slug":"%e5%a6%82%e4%bd%95%e7%bb%99python%e5%8a%a0%e8%bd%bd%e6%a8%a1%e5%9d%97","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/1002683.html","title":{"rendered":"\u5982\u4f55\u7ed9python\u52a0\u8f7d\u6a21\u5757"},"content":{"rendered":"<p style=\"text-align:center;\" ><img decoding=\"async\" src=\"https:\/\/cdn-kb.worktile.com\/kb\/wp-content\/uploads\/2024\/04\/25080336\/40e57137-9787-4392-a658-10a6c39150c4.webp\" alt=\"\u5982\u4f55\u7ed9python\u52a0\u8f7d\u6a21\u5757\" \/><\/p>\n<p><p> \u5728Python\u4e2d\uff0c<strong>\u52a0\u8f7d\u6a21\u5757\u7684\u65b9\u6cd5\u4e3b\u8981\u5305\u62ec\u4f7f\u7528import\u8bed\u53e5\u3001from&#8230;import\u8bed\u53e5\u3001importlib\u6a21\u5757\u3001sys.path\u4fee\u6539\u8def\u5f84\u7b49<\/strong>\u3002\u5176\u4e2d\uff0c\u6700\u5e38\u7528\u7684\u65b9\u5f0f\u662f\u901a\u8fc7<code>import<\/code>\u8bed\u53e5\u6765\u52a0\u8f7d\u6a21\u5757\u3002\u5177\u4f53\u6765\u8bf4\uff0c\u4f7f\u7528<code>import<\/code>\u8bed\u53e5\u53ef\u4ee5\u76f4\u63a5\u5bfc\u5165\u6574\u4e2a\u6a21\u5757\uff0c\u4f8b\u5982<code>import math<\/code>\uff0c\u8fd9\u6837\u5c31\u53ef\u4ee5\u4f7f\u7528<code>math<\/code>\u6a21\u5757\u4e2d\u7684\u51fd\u6570\u548c\u53d8\u91cf\uff1b\u800c<code>from...import<\/code>\u8bed\u53e5\u5219\u53ef\u4ee5\u5bfc\u5165\u6a21\u5757\u4e2d\u7684\u7279\u5b9a\u90e8\u5206\uff0c\u4f8b\u5982<code>from math import sqrt<\/code>\uff0c\u8fd9\u4f1a\u76f4\u63a5\u5bfc\u5165<code>math<\/code>\u6a21\u5757\u4e2d\u7684<code>sqrt<\/code>\u51fd\u6570\u3002\u4e0b\u9762\u5c06\u8be6\u7ec6\u4ecb\u7ecd\u8fd9\u4e9b\u65b9\u6cd5\u4ee5\u53ca\u5b83\u4eec\u7684\u4f7f\u7528\u573a\u666f\u548c\u6ce8\u610f\u4e8b\u9879\u3002<\/p>\n<\/p>\n<p><p>\u4e00\u3001IMPORT\u8bed\u53e5<\/p>\n<\/p>\n<p><p><code>import<\/code>\u8bed\u53e5\u662fPython\u4e2d\u52a0\u8f7d\u6a21\u5757\u6700\u5e38\u7528\u7684\u65b9\u6cd5\u3002\u901a\u8fc7\u8fd9\u4e2a\u8bed\u53e5\uff0c\u6211\u4eec\u53ef\u4ee5\u5c06\u6574\u4e2a\u6a21\u5757\u5bfc\u5165\u5230\u5f53\u524d\u547d\u540d\u7a7a\u95f4\u4e2d\uff0c\u4ece\u800c\u4f7f\u7528\u6a21\u5757\u4e2d\u7684\u51fd\u6570\u3001\u7c7b\u548c\u53d8\u91cf\u3002<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>\u57fa\u672c\u7528\u6cd5<\/strong><\/p>\n<\/p>\n<p><p>\u4f7f\u7528<code>import<\/code>\u8bed\u53e5\u53ef\u4ee5\u5bfc\u5165\u4e00\u4e2a\u6a21\u5757\u7684\u5b8c\u6574\u529f\u80fd\u3002\u4f8b\u5982\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import math<\/p>\n<p>print(math.sqrt(16))<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u4e0a\u8ff0\u4ee3\u7801\u5bfc\u5165\u4e86<code>math<\/code>\u6a21\u5757\uff0c\u5e76\u4f7f\u7528\u4e86\u5176\u4e2d\u7684<code>sqrt<\/code>\u51fd\u6570\u6765\u8ba1\u7b9716\u7684\u5e73\u65b9\u6839\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u6a21\u5757\u522b\u540d<\/strong><\/p>\n<\/p>\n<p><p>\u5982\u679c\u6a21\u5757\u540d\u8f83\u957f\u6216\u8005\u4e3a\u4e86\u907f\u514d\u547d\u540d\u51b2\u7a81\uff0c\u53ef\u4ee5\u4f7f\u7528<code>as<\/code>\u5173\u952e\u5b57\u4e3a\u6a21\u5757\u521b\u5efa\u4e00\u4e2a\u522b\u540d\u3002\u4f8b\u5982\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import numpy as np<\/p>\n<p>print(np.array([1, 2, 3]))<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u901a\u8fc7\u8fd9\u79cd\u65b9\u5f0f\uff0c\u6211\u4eec\u53ef\u4ee5\u4f7f\u7528<code>np<\/code>\u6765\u4ee3\u66ff<code>numpy<\/code>\u6a21\u5757\u7684\u540d\u79f0\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u4e8c\u3001FROM&#8230;IMPORT\u8bed\u53e5<\/p>\n<\/p>\n<p><p><code>from...import<\/code>\u8bed\u53e5\u53ef\u4ee5\u5bfc\u5165\u6a21\u5757\u4e2d\u7684\u7279\u5b9a\u90e8\u5206\uff0c\u800c\u4e0d\u662f\u6574\u4e2a\u6a21\u5757\u3002\u8fd9\u5728\u9700\u8981\u4f7f\u7528\u6a21\u5757\u4e2d\u67d0\u51e0\u4e2a\u529f\u80fd\u65f6\u975e\u5e38\u6709\u7528\u3002<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>\u5bfc\u5165\u7279\u5b9a\u529f\u80fd<\/strong><\/p>\n<\/p>\n<p><p>\u53ef\u4ee5\u4ece\u6a21\u5757\u4e2d\u5bfc\u5165\u7279\u5b9a\u7684\u51fd\u6570\u3001\u7c7b\u6216\u53d8\u91cf\u3002\u4f8b\u5982\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">from math import pi, sqrt<\/p>\n<p>print(pi)<\/p>\n<p>print(sqrt(25))<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u8fd9\u79cd\u65b9\u6cd5\u907f\u514d\u4e86\u5bfc\u5165\u6574\u4e2a\u6a21\u5757\uff0c\u8282\u7701\u4e86\u5185\u5b58\u548c\u52a0\u8f7d\u65f6\u95f4\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u5bfc\u5165\u6240\u6709\u529f\u80fd<\/strong><\/p>\n<\/p>\n<p><p>\u4f7f\u7528\u661f\u53f7\uff08*\uff09\u53ef\u4ee5\u5bfc\u5165\u6a21\u5757\u4e2d\u7684\u6240\u6709\u529f\u80fd\uff0c\u4f46\u8fd9\u79cd\u65b9\u5f0f\u4e0d\u63a8\u8350\u4f7f\u7528\uff0c\u56e0\u4e3a\u53ef\u80fd\u4f1a\u5bfc\u81f4\u547d\u540d\u51b2\u7a81\u3002\u4f8b\u5982\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">from math import *<\/p>\n<p>print(cos(0))<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5c3d\u7ba1\u8fd9\u79cd\u65b9\u5f0f\u53ef\u4ee5\u7b80\u5316\u4ee3\u7801\u7f16\u5199\uff0c\u4f46\u53ef\u80fd\u5bfc\u81f4\u547d\u540d\u51b2\u7a81\u548c\u53ef\u8bfb\u6027\u4e0b\u964d\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u4e09\u3001IMPORTLIB\u6a21\u5757<\/p>\n<\/p>\n<p><p><code>importlib<\/code>\u6a21\u5757\u63d0\u4f9b\u4e86\u66f4\u7075\u6d3b\u7684\u6a21\u5757\u52a0\u8f7d\u65b9\u5f0f\uff0c\u7279\u522b\u9002\u5408\u52a8\u6001\u52a0\u8f7d\u6a21\u5757\u7684\u573a\u666f\u3002<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>\u52a8\u6001\u52a0\u8f7d<\/strong><\/p>\n<\/p>\n<p><p>\u4f7f\u7528<code>importlib.import_module<\/code>\u53ef\u4ee5\u5728\u8fd0\u884c\u65f6\u52a8\u6001\u52a0\u8f7d\u6a21\u5757\u3002\u4f8b\u5982\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import importlib<\/p>\n<p>module_name = &#39;math&#39;<\/p>\n<p>math_module = importlib.import_module(module_name)<\/p>\n<p>print(math_module.sqrt(36))<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u8fd9\u79cd\u65b9\u5f0f\u9002\u5408\u9700\u8981\u6839\u636e\u4e0d\u540c\u6761\u4ef6\u52a0\u8f7d\u4e0d\u540c\u6a21\u5757\u7684\u573a\u666f\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u91cd\u65b0\u52a0\u8f7d\u6a21\u5757<\/strong><\/p>\n<\/p>\n<p><p><code>importlib.reload<\/code>\u53ef\u4ee5\u91cd\u65b0\u52a0\u8f7d\u5df2\u7ecf\u5bfc\u5165\u7684\u6a21\u5757\uff0c\u8fd9\u5728\u8c03\u8bd5\u65f6\u975e\u5e38\u6709\u7528\u3002\u4f8b\u5982\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import importlib<\/p>\n<p>import some_module<\/p>\n<h2><strong>\u4fee\u6539 some_module \u540e\u91cd\u65b0\u52a0\u8f7d<\/strong><\/h2>\n<p>importlib.reload(some_module)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u901a\u8fc7\u8fd9\u79cd\u65b9\u5f0f\uff0c\u6211\u4eec\u53ef\u4ee5\u5728\u4e0d\u91cd\u542f\u89e3\u91ca\u5668\u7684\u60c5\u51b5\u4e0b\u66f4\u65b0\u6a21\u5757\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u56db\u3001SYS.PATH\u4fee\u6539\u8def\u5f84<\/p>\n<\/p>\n<p><p>\u5728\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0cPython\u4f1a\u5728<code>sys.path<\/code>\u4e2d\u5217\u51fa\u7684\u76ee\u5f55\u4e2d\u641c\u7d22\u6a21\u5757\u3002\u5982\u679c\u6a21\u5757\u4e0d\u5728\u8fd9\u4e9b\u76ee\u5f55\u4e2d\uff0c\u6211\u4eec\u53ef\u4ee5\u901a\u8fc7\u4fee\u6539<code>sys.path<\/code>\u6765\u6307\u5b9a\u65b0\u7684\u641c\u7d22\u8def\u5f84\u3002<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>\u67e5\u770b\u548c\u4fee\u6539\u641c\u7d22\u8def\u5f84<\/strong><\/p>\n<\/p>\n<p><p>\u53ef\u4ee5\u901a\u8fc7<code>sys.path<\/code>\u67e5\u770b\u5f53\u524d\u7684\u641c\u7d22\u8def\u5f84\uff0c\u5e76\u5728\u9700\u8981\u65f6\u8fdb\u884c\u4fee\u6539\u3002\u4f8b\u5982\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import sys<\/p>\n<p>print(sys.path)<\/p>\n<p>sys.path.append(&#39;\/path\/to\/module_directory&#39;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u901a\u8fc7\u8fd9\u79cd\u65b9\u5f0f\uff0c\u6211\u4eec\u53ef\u4ee5\u5c06\u81ea\u5b9a\u4e49\u6a21\u5757\u6240\u5728\u7684\u76ee\u5f55\u6dfb\u52a0\u5230\u641c\u7d22\u8def\u5f84\u4e2d\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u6c38\u4e45\u4fee\u6539\u8def\u5f84<\/strong><\/p>\n<\/p>\n<p><p>\u53ef\u4ee5\u901a\u8fc7\u4fee\u6539\u73af\u5883\u53d8\u91cf<code>PYTHONPATH<\/code>\u6765\u6c38\u4e45\u6539\u53d8\u641c\u7d22\u8def\u5f84\u3002\u4f8b\u5982\uff0c\u5728Linux\u7cfb\u7edf\u4e2d\uff0c\u53ef\u4ee5\u5728<code>.bashrc<\/code>\u6587\u4ef6\u4e2d\u6dfb\u52a0\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-bash\">export PYTHONPATH=&quot;${PYTHONPATH}:\/path\/to\/module_directory&quot;<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u8fd9\u6837\u8bbe\u7f6e\u540e\uff0c\u6bcf\u6b21\u542f\u52a8Python\u89e3\u91ca\u5668\u65f6\u90fd\u4f1a\u81ea\u52a8\u52a0\u8f7d\u8fd9\u4e9b\u8def\u5f84\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u4e94\u3001\u5305\u7684\u52a0\u8f7d<\/p>\n<\/p>\n<p><p>\u5f53\u6211\u4eec\u9700\u8981\u7ec4\u7ec7\u591a\u4e2a\u6a21\u5757\u65f6\uff0c\u53ef\u4ee5\u4f7f\u7528\u5305\u6765\u7ba1\u7406\u3002\u5305\u5b9e\u9645\u4e0a\u662f\u4e00\u4e2a\u5305\u542b<code>__init__.py<\/code>\u6587\u4ef6\u7684\u76ee\u5f55\uff0c\u53ef\u4ee5\u5305\u542b\u591a\u4e2a\u6a21\u5757\u3002<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>\u5bfc\u5165\u5305\u4e2d\u7684\u6a21\u5757<\/strong><\/p>\n<\/p>\n<p><p>\u901a\u8fc7<code>import<\/code>\u8bed\u53e5\u53ef\u4ee5\u5bfc\u5165\u5305\u4e2d\u7684\u6a21\u5757\u3002\u4f8b\u5982\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import mypackage.mymodule<\/p>\n<p>mypackage.mymodule.my_function()<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u8fd9\u79cd\u65b9\u5f0f\u53ef\u4ee5\u5e2e\u52a9\u6211\u4eec\u66f4\u597d\u5730\u7ec4\u7ec7\u4ee3\u7801\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u4f7f\u7528\u76f8\u5bf9\u5bfc\u5165<\/strong><\/p>\n<\/p>\n<p><p>\u5728\u5305\u5185\u90e8\uff0c\u6a21\u5757\u4e4b\u95f4\u53ef\u4ee5\u4f7f\u7528\u76f8\u5bf9\u5bfc\u5165\u3002\u4f8b\u5982\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">from . import sibling_module<\/p>\n<p>from .. import parent_module<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u76f8\u5bf9\u5bfc\u5165\u53ef\u4ee5\u63d0\u9ad8\u4ee3\u7801\u7684\u53ef\u79fb\u690d\u6027\u548c\u53ef\u8bfb\u6027\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u603b\u7ed3\u6765\u8bf4\uff0cPython\u63d0\u4f9b\u4e86\u591a\u79cd\u52a0\u8f7d\u6a21\u5757\u7684\u65b9\u6cd5\uff0c\u6bcf\u79cd\u65b9\u6cd5\u90fd\u6709\u5176\u9002\u7528\u7684\u573a\u666f\u548c\u6ce8\u610f\u4e8b\u9879\u3002\u5728\u5b9e\u9645\u5e94\u7528\u4e2d\uff0c\u9009\u62e9\u5408\u9002\u7684\u52a0\u8f7d\u65b9\u5f0f\u53ef\u4ee5\u63d0\u9ad8\u4ee3\u7801\u7684\u6548\u7387\u548c\u53ef\u7ef4\u62a4\u6027\u3002\u65e0\u8bba\u662f\u901a\u8fc7<code>import<\/code>\u8bed\u53e5\u3001<code>from...import<\/code>\u8bed\u53e5\u3001<code>importlib<\/code>\u6a21\u5757\uff0c\u8fd8\u662f\u901a\u8fc7\u4fee\u6539<code>sys.path<\/code>\uff0c\u6211\u4eec\u90fd\u53ef\u4ee5\u7075\u6d3b\u5730\u52a0\u8f7d\u548c\u7ba1\u7406Python\u6a21\u5757\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p> <strong>\u5982\u4f55\u5728Python\u4e2d\u67e5\u627e\u53ef\u7528\u6a21\u5757\u7684\u5217\u8868\uff1f<\/strong><br \/>\u60a8\u53ef\u4ee5\u4f7f\u7528\u5185\u7f6e\u7684<code>help(&#39;modules&#39;)<\/code>\u547d\u4ee4\u5728Python\u4ea4\u4e92\u5f0f\u73af\u5883\u4e2d\u67e5\u770b\u5f53\u524d\u53ef\u7528\u7684\u6a21\u5757\u5217\u8868\u3002\u6b64\u547d\u4ee4\u5c06\u5217\u51fa\u6240\u6709\u5df2\u5b89\u88c5\u7684\u6a21\u5757\uff0c\u5e2e\u52a9\u60a8\u4e86\u89e3\u53ef\u4ee5\u52a0\u8f7d\u54ea\u4e9b\u529f\u80fd\u3002<\/p>\n<p><strong>\u5728Python\u4e2d\u52a0\u8f7d\u6a21\u5757\u65f6\uff0c\u5982\u4f55\u5904\u7406\u6a21\u5757\u5bfc\u5165\u9519\u8bef\uff1f<\/strong><br \/>\u5f53\u60a8\u5c1d\u8bd5\u52a0\u8f7d\u4e00\u4e2a\u6a21\u5757\u4f46\u9047\u5230\u5bfc\u5165\u9519\u8bef\u65f6\uff0c\u901a\u5e38\u662f\u56e0\u4e3a\u8be5\u6a21\u5757\u672a\u5b89\u88c5\u6216\u8def\u5f84\u8bbe\u7f6e\u4e0d\u6b63\u786e\u3002\u60a8\u53ef\u4ee5\u4f7f\u7528<code>pip<\/code>\u547d\u4ee4\u5b89\u88c5\u7f3a\u5931\u7684\u6a21\u5757\uff0c\u4f8b\u5982<code>pip install module_name<\/code>\uff0c\u5e76\u786e\u4fdd\u6a21\u5757\u8def\u5f84\u5305\u542b\u5728<code>sys.path<\/code>\u4e2d\uff0c\u53ef\u4ee5\u901a\u8fc7<code>import sys<\/code>\u548c<code>print(sys.path)<\/code>\u8fdb\u884c\u68c0\u67e5\u548c\u4fee\u6539\u3002<\/p>\n<p><strong>\u4f7f\u7528\u865a\u62df\u73af\u5883\u65f6\uff0c\u5982\u4f55\u786e\u4fdd\u6a21\u5757\u6b63\u786e\u52a0\u8f7d\uff1f<\/strong><br \/>\u5728\u4f7f\u7528\u865a\u62df\u73af\u5883\u65f6\uff0c\u786e\u4fdd\u60a8\u5df2\u6fc0\u6d3b\u8be5\u73af\u5883\u3002\u6fc0\u6d3b\u540e\uff0c\u60a8\u53ef\u4ee5\u4f7f\u7528<code>pip install<\/code>\u547d\u4ee4\u5b89\u88c5\u6240\u9700\u7684\u6a21\u5757\uff0c\u8fd9\u6837\u5b83\u4eec\u5c31\u4f1a\u88ab\u52a0\u8f7d\u5230\u8be5\u7279\u5b9a\u73af\u5883\u4e2d\u3002\u4f7f\u7528<code>venv<\/code>\u6216<code>conda<\/code>\u7b49\u5de5\u5177\u521b\u5efa\u548c\u7ba1\u7406\u865a\u62df\u73af\u5883\uff0c\u53ef\u4ee5\u5e2e\u52a9\u9694\u79bb\u9879\u76ee\u7684\u4f9d\u8d56\u5173\u7cfb\uff0c\u907f\u514d\u6a21\u5757\u51b2\u7a81\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"\u5728Python\u4e2d\uff0c\u52a0\u8f7d\u6a21\u5757\u7684\u65b9\u6cd5\u4e3b\u8981\u5305\u62ec\u4f7f\u7528import\u8bed\u53e5\u3001from&#8230;import\u8bed\u53e5\u3001impo [&hellip;]","protected":false},"author":3,"featured_media":1002692,"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\/1002683"}],"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=1002683"}],"version-history":[{"count":"1","href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1002683\/revisions"}],"predecessor-version":[{"id":1002695,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1002683\/revisions\/1002695"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/1002692"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=1002683"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=1002683"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=1002683"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}