{"id":1033587,"date":"2024-12-31T11:43:09","date_gmt":"2024-12-31T03:43:09","guid":{"rendered":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/1033587.html"},"modified":"2024-12-31T11:43:12","modified_gmt":"2024-12-31T03:43:12","slug":"python%e5%a6%82%e4%bd%95%e5%b0%86txt%e8%bd%ac%e6%8d%a2%e4%b8%bamat","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/1033587.html","title":{"rendered":"python\u5982\u4f55\u5c06txt\u8f6c\u6362\u4e3amat"},"content":{"rendered":"<p style=\"text-align:center;\" ><img decoding=\"async\" src=\"https:\/\/cdn-docs.pingcode.com\/wp-content\/uploads\/2024\/12\/141fab80-6740-42fc-bde4-328955b03e92.webp?x-oss-process=image\/auto-orient,1\/format,webp\" alt=\"python\u5982\u4f55\u5c06txt\u8f6c\u6362\u4e3amat\" \/><\/p>\n<p><p> <strong>\u4f7f\u7528Python\u5c06txt\u8f6c\u6362\u4e3amat\u6587\u4ef6\u7684\u5173\u952e\u6b65\u9aa4\u5305\u62ec\uff1a\u8bfb\u53d6txt\u6587\u4ef6\u3001\u5904\u7406\u6570\u636e\u3001\u5c06\u6570\u636e\u5199\u5165mat\u6587\u4ef6\u3002<\/strong><\/p>\n<\/p>\n<p><p><strong>\u6b65\u9aa4\uff1a\u8bfb\u53d6txt\u6587\u4ef6\u3001\u5904\u7406\u6570\u636e\u3001\u5c06\u6570\u636e\u5199\u5165mat\u6587\u4ef6\u3002<\/strong>\u5176\u4e2d\uff0c\u5904\u7406\u6570\u636e\u662f\u5173\u952e\u6b65\u9aa4\u3002\u8be6\u7ec6\u63cf\u8ff0\u5982\u4e0b\uff1a\u5728\u8bfb\u53d6txt\u6587\u4ef6\u4e4b\u540e\uff0c\u9700\u8981\u6839\u636etxt\u6587\u4ef6\u7684\u5185\u5bb9\u683c\u5f0f\uff08\u5982\u662f\u5426\u5305\u542b\u6807\u9898\u884c\u3001\u5206\u9694\u7b26\u7b49\uff09\u6765\u89e3\u6790\u6570\u636e\uff0c\u5e76\u5c06\u5176\u8f6c\u6362\u6210\u9002\u5f53\u7684\u6570\u636e\u7ed3\u6784\uff08\u5982NumPy\u6570\u7ec4\u6216\u5b57\u5178\uff09\uff0c\u4ee5\u4fbf\u540e\u7eed\u5199\u5165mat\u6587\u4ef6\u3002<\/p>\n<\/p>\n<p><p>\u4e00\u3001\u8bfb\u53d6txt\u6587\u4ef6<\/p>\n<\/p>\n<p><p>\u8bfb\u53d6txt\u6587\u4ef6\u662f\u5c06\u5176\u4e2d\u7684\u6570\u636e\u52a0\u8f7d\u5230Python\u4e2d\u7684\u7b2c\u4e00\u6b65\u3002\u6839\u636etxt\u6587\u4ef6\u7684\u5185\u5bb9\u683c\u5f0f\uff0c\u53ef\u4ee5\u4f7f\u7528\u4e0d\u540c\u7684\u65b9\u6cd5\u8fdb\u884c\u8bfb\u53d6\u3002\u5e38\u7528\u7684\u65b9\u6cd5\u5305\u62ec\u4f7f\u7528Python\u5185\u7f6e\u7684open\u51fd\u6570\u3001\u4f7f\u7528NumPy\u5e93\u4e2d\u7684loadtxt\u51fd\u6570\u3001\u4ee5\u53ca\u4f7f\u7528Pandas\u5e93\u4e2d\u7684read_csv\u51fd\u6570\u3002<\/p>\n<\/p>\n<ol>\n<li>\u4f7f\u7528open\u51fd\u6570\u8bfb\u53d6txt\u6587\u4ef6<\/li>\n<\/ol>\n<p><pre><code class=\"language-python\">with open(&#39;data.txt&#39;, &#39;r&#39;) as file:<\/p>\n<p>    lines = file.readlines()<\/p>\n<p>    data = [line.strip().split() for line in lines]<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5728\u4e0a\u8ff0\u4ee3\u7801\u4e2d\uff0c<code>open<\/code>\u51fd\u6570\u6253\u5f00txt\u6587\u4ef6\uff0c<code>readlines<\/code>\u51fd\u6570\u8bfb\u53d6\u6240\u6709\u884c\uff0c\u5e76\u4f7f\u7528<code>strip<\/code>\u548c<code>split<\/code>\u51fd\u6570\u5bf9\u6bcf\u4e00\u884c\u8fdb\u884c\u5904\u7406\uff0c\u4ee5\u5c06\u5176\u8f6c\u5316\u4e3aPython\u5217\u8868\u3002<\/p>\n<\/p>\n<ol start=\"2\">\n<li>\u4f7f\u7528NumPy\u7684loadtxt\u51fd\u6570\u8bfb\u53d6txt\u6587\u4ef6<\/li>\n<\/ol>\n<p><pre><code class=\"language-python\">import numpy as np<\/p>\n<p>data = np.loadtxt(&#39;data.txt&#39;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u4e0a\u8ff0\u4ee3\u7801\u4f7f\u7528NumPy\u5e93\u7684<code>loadtxt<\/code>\u51fd\u6570\u8bfb\u53d6txt\u6587\u4ef6\u4e2d\u7684\u6570\u636e\uff0c\u5e76\u5c06\u5176\u8f6c\u5316\u4e3aNumPy\u6570\u7ec4\u3002<code>loadtxt<\/code>\u51fd\u6570\u53ef\u4ee5\u5904\u7406\u5404\u79cd\u5206\u9694\u7b26\u3001\u8df3\u8fc7\u7279\u5b9a\u884c\u7b49\u3002<\/p>\n<\/p>\n<ol start=\"3\">\n<li>\u4f7f\u7528Pandas\u7684read_csv\u51fd\u6570\u8bfb\u53d6txt\u6587\u4ef6<\/li>\n<\/ol>\n<p><pre><code class=\"language-python\">import pandas as pd<\/p>\n<p>data = pd.read_csv(&#39;data.txt&#39;, delimiter=&#39;\\t&#39;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u4e0a\u8ff0\u4ee3\u7801\u4f7f\u7528Pandas\u5e93\u7684<code>read_csv<\/code>\u51fd\u6570\u8bfb\u53d6txt\u6587\u4ef6\u4e2d\u7684\u6570\u636e\uff0c\u5e76\u5c06\u5176\u8f6c\u5316\u4e3aPandas DataFrame\u3002<code>delimiter<\/code>\u53c2\u6570\u53ef\u4ee5\u6307\u5b9atxt\u6587\u4ef6\u4e2d\u7684\u5206\u9694\u7b26\u3002<\/p>\n<\/p>\n<p><p>\u4e8c\u3001\u5904\u7406\u6570\u636e<\/p>\n<\/p>\n<p><p>\u5904\u7406\u6570\u636e\u662f\u5c06\u8bfb\u53d6\u7684txt\u6587\u4ef6\u6570\u636e\u8f6c\u5316\u4e3a\u9002\u5f53\u7684\u6570\u636e\u7ed3\u6784\uff0c\u4ee5\u4fbf\u540e\u7eed\u5199\u5165mat\u6587\u4ef6\u3002\u5e38\u7528\u7684\u6570\u636e\u7ed3\u6784\u5305\u62ecNumPy\u6570\u7ec4\u548c\u5b57\u5178\u3002<\/p>\n<\/p>\n<ol>\n<li>\u5c06\u6570\u636e\u8f6c\u6362\u4e3aNumPy\u6570\u7ec4<\/li>\n<\/ol>\n<p><pre><code class=\"language-python\">import numpy as np<\/p>\n<p>data_array = np.array(data)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u4e0a\u8ff0\u4ee3\u7801\u4f7f\u7528NumPy\u7684<code>array<\/code>\u51fd\u6570\u5c06\u6570\u636e\u8f6c\u6362\u4e3aNumPy\u6570\u7ec4\u3002<\/p>\n<\/p>\n<ol start=\"2\">\n<li>\u5c06\u6570\u636e\u8f6c\u6362\u4e3a\u5b57\u5178<\/li>\n<\/ol>\n<p><pre><code class=\"language-python\">data_dict = {&#39;data&#39;: data}<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u4e0a\u8ff0\u4ee3\u7801\u5c06\u6570\u636e\u8f6c\u6362\u4e3aPython\u5b57\u5178\uff0c\u5176\u4e2d\u952e\u4e3a&#39;data&#39;\uff0c\u503c\u4e3a\u8bfb\u53d6\u7684txt\u6587\u4ef6\u6570\u636e\u3002<\/p>\n<\/p>\n<p><p>\u4e09\u3001\u5c06\u6570\u636e\u5199\u5165mat\u6587\u4ef6<\/p>\n<\/p>\n<p><p>\u5c06\u6570\u636e\u5199\u5165mat\u6587\u4ef6\u662f\u5c06\u5904\u7406\u540e\u7684\u6570\u636e\u4fdd\u5b58\u4e3aMATLAB\u683c\u5f0f\u6587\u4ef6\u3002\u5e38\u7528\u7684\u65b9\u6cd5\u662f\u4f7f\u7528SciPy\u5e93\u4e2d\u7684savemat\u51fd\u6570\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">from scipy.io import savemat<\/p>\n<p>savemat(&#39;data.mat&#39;, data_dict)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u4e0a\u8ff0\u4ee3\u7801\u4f7f\u7528SciPy\u5e93\u7684<code>savemat<\/code>\u51fd\u6570\u5c06\u6570\u636e\u5b57\u5178\u4fdd\u5b58\u4e3amat\u6587\u4ef6\u3002<\/p>\n<\/p>\n<p><p>\u56db\u3001\u5b8c\u6574\u793a\u4f8b<\/p>\n<\/p>\n<p><p>\u7efc\u5408\u4e0a\u8ff0\u6b65\u9aa4\uff0c\u6211\u4eec\u53ef\u4ee5\u7f16\u5199\u4e00\u4e2a\u5b8c\u6574\u7684\u793a\u4f8b\uff0c\u5c06txt\u6587\u4ef6\u8f6c\u6362\u4e3amat\u6587\u4ef6\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import numpy as np<\/p>\n<p>from scipy.io import savemat<\/p>\n<h2><strong>\u8bfb\u53d6txt\u6587\u4ef6<\/strong><\/h2>\n<p>data = np.loadtxt(&#39;data.txt&#39;)<\/p>\n<h2><strong>\u5c06\u6570\u636e\u8f6c\u6362\u4e3a\u5b57\u5178<\/strong><\/h2>\n<p>data_dict = {&#39;data&#39;: data}<\/p>\n<h2><strong>\u5c06\u6570\u636e\u5199\u5165mat\u6587\u4ef6<\/strong><\/h2>\n<p>savemat(&#39;data.mat&#39;, data_dict)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u4e0a\u8ff0\u4ee3\u7801\u5c55\u793a\u4e86\u5982\u4f55\u4f7f\u7528NumPy\u548cSciPy\u5e93\u5c06txt\u6587\u4ef6\u8f6c\u6362\u4e3amat\u6587\u4ef6\u7684\u5b8c\u6574\u6d41\u7a0b\u3002\u901a\u8fc7\u8fd9\u79cd\u65b9\u5f0f\uff0c\u53ef\u4ee5\u65b9\u4fbf\u5730\u5728Python\u4e2d\u5904\u7406\u548c\u8f6c\u6362\u6570\u636e\u683c\u5f0f\uff0c\u4ee5\u6ee1\u8db3\u4e0d\u540c\u7684\u9700\u6c42\u3002<\/p>\n<\/p>\n<p><p>\u4e94\u3001\u8fdb\u9636\u5904\u7406<\/p>\n<\/p>\n<p><p>\u5728\u5b9e\u9645\u5e94\u7528\u4e2d\uff0ctxt\u6587\u4ef6\u7684\u5185\u5bb9\u683c\u5f0f\u53ef\u80fd\u66f4\u52a0\u590d\u6742\uff0c\u4f8b\u5982\u5305\u542b\u6807\u9898\u884c\u3001\u6ce8\u91ca\u884c\u3001\u7f3a\u5931\u503c\u7b49\u3002\u4e3a\u4e86\u5904\u7406\u8fd9\u4e9b\u590d\u6742\u60c5\u51b5\uff0c\u53ef\u4ee5\u4f7f\u7528\u66f4\u591a\u9ad8\u7ea7\u7684\u529f\u80fd\u548c\u53c2\u6570\u3002<\/p>\n<\/p>\n<ol>\n<li>\u5904\u7406\u6807\u9898\u884c\u548c\u6ce8\u91ca\u884c<\/li>\n<\/ol>\n<p><pre><code class=\"language-python\">import pandas as pd<\/p>\n<p>data = pd.read_csv(&#39;data.txt&#39;, delimiter=&#39;\\t&#39;, header=0, comment=&#39;#&#39;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u4e0a\u8ff0\u4ee3\u7801\u4f7f\u7528Pandas\u5e93\u7684<code>read_csv<\/code>\u51fd\u6570\uff0c\u5e76\u901a\u8fc7<code>header<\/code>\u53c2\u6570\u6307\u5b9a\u6807\u9898\u884c\uff0c\u901a\u8fc7<code>comment<\/code>\u53c2\u6570\u5ffd\u7565\u6ce8\u91ca\u884c\u3002<\/p>\n<\/p>\n<ol start=\"2\">\n<li>\u5904\u7406\u7f3a\u5931\u503c<\/li>\n<\/ol>\n<p><pre><code class=\"language-python\">import pandas as pd<\/p>\n<p>data = pd.read_csv(&#39;data.txt&#39;, delimiter=&#39;\\t&#39;, na_values=[&#39;NA&#39;, &#39;nan&#39;])<\/p>\n<p>data.fillna(0, inplace=True)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u4e0a\u8ff0\u4ee3\u7801\u4f7f\u7528Pandas\u5e93\u7684<code>read_csv<\/code>\u51fd\u6570\uff0c\u5e76\u901a\u8fc7<code>na_values<\/code>\u53c2\u6570\u5c06\u7279\u5b9a\u5b57\u7b26\u4e32\u8bc6\u522b\u4e3a\u7f3a\u5931\u503c\uff0c\u4f7f\u7528<code>fillna<\/code>\u51fd\u6570\u586b\u5145\u7f3a\u5931\u503c\u3002<\/p>\n<\/p>\n<ol start=\"3\">\n<li>\u81ea\u5b9a\u4e49\u6570\u636e\u89e3\u6790<\/li>\n<\/ol>\n<p><pre><code class=\"language-python\">import numpy as np<\/p>\n<p>def custom_parser(line):<\/p>\n<p>    return [float(x) if x else 0 for x in line.strip().split()]<\/p>\n<p>with open(&#39;data.txt&#39;, &#39;r&#39;) as file:<\/p>\n<p>    data = [custom_parser(line) for line in file]<\/p>\n<p>data_array = np.array(data)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u4e0a\u8ff0\u4ee3\u7801\u5b9a\u4e49\u4e86\u4e00\u4e2a\u81ea\u5b9a\u4e49\u89e3\u6790\u51fd\u6570<code>custom_parser<\/code>\uff0c\u5e76\u5728\u8bfb\u53d6txt\u6587\u4ef6\u65f6\u8c03\u7528\u8be5\u51fd\u6570\u5bf9\u6bcf\u4e00\u884c\u8fdb\u884c\u5904\u7406\uff0c\u4ee5\u5e94\u5bf9\u66f4\u52a0\u590d\u6742\u7684\u5185\u5bb9\u683c\u5f0f\u3002<\/p>\n<\/p>\n<p><p>\u516d\u3001\u603b\u7ed3<\/p>\n<\/p>\n<p><p>\u4f7f\u7528Python\u5c06txt\u6587\u4ef6\u8f6c\u6362\u4e3amat\u6587\u4ef6\u7684\u8fc7\u7a0b\u5305\u62ec\u8bfb\u53d6txt\u6587\u4ef6\u3001\u5904\u7406\u6570\u636e\u3001\u5c06\u6570\u636e\u5199\u5165mat\u6587\u4ef6\u3002\u901a\u8fc7\u4f7f\u7528Python\u7684\u5185\u7f6e\u51fd\u6570\u3001NumPy\u5e93\u548cPandas\u5e93\uff0c\u53ef\u4ee5\u65b9\u4fbf\u5730\u8bfb\u53d6\u548c\u5904\u7406txt\u6587\u4ef6\u4e2d\u7684\u6570\u636e\u3002\u901a\u8fc7\u4f7f\u7528SciPy\u5e93\u7684savemat\u51fd\u6570\uff0c\u53ef\u4ee5\u5c06\u5904\u7406\u540e\u7684\u6570\u636e\u4fdd\u5b58\u4e3aMATLAB\u683c\u5f0f\u6587\u4ef6\u3002\u5728\u5b9e\u9645\u5e94\u7528\u4e2d\uff0c\u53ef\u4ee5\u6839\u636etxt\u6587\u4ef6\u7684\u5185\u5bb9\u683c\u5f0f\u548c\u9700\u6c42\uff0c\u4f7f\u7528\u66f4\u591a\u9ad8\u7ea7\u529f\u80fd\u548c\u53c2\u6570\uff0c\u4ee5\u5904\u7406\u590d\u6742\u60c5\u51b5\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p> <strong>\u5982\u4f55\u4f7f\u7528Python\u8bfb\u53d6txt\u6587\u4ef6\u4e2d\u7684\u6570\u636e\uff1f<\/strong><br \/>\u5728Python\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528\u5185\u7f6e\u7684<code>open()<\/code>\u51fd\u6570\u6216<code>pandas<\/code>\u5e93\u6765\u8bfb\u53d6txt\u6587\u4ef6\u4e2d\u7684\u6570\u636e\u3002\u82e5\u6570\u636e\u662f\u4ee5\u7279\u5b9a\u5206\u9694\u7b26\uff08\u5982\u9017\u53f7\u6216\u7a7a\u683c\uff09\u5206\u9694\u7684\uff0c\u53ef\u4ee5\u4f7f\u7528<code>pandas.read_csv()<\/code>\u65b9\u6cd5\u6765\u8bfb\u53d6\uff0c\u5e76\u6307\u5b9a\u5206\u9694\u7b26\u3002\u8fd9\u6837\u53ef\u4ee5\u65b9\u4fbf\u5730\u5c06\u6570\u636e\u52a0\u8f7d\u5230DataFrame\u4e2d\uff0c\u4ee5\u4fbf\u540e\u7eed\u5904\u7406\u3002<\/p>\n<p><strong>\u5c06txt\u6587\u4ef6\u8f6c\u6362\u4e3amat\u6587\u4ef6\u65f6\u9700\u8981\u6ce8\u610f\u54ea\u4e9b\u683c\u5f0f\u95ee\u9898\uff1f<\/strong><br \/>\u5728\u8f6c\u6362\u8fc7\u7a0b\u4e2d\uff0c\u9700\u8981\u786e\u4fddtxt\u6587\u4ef6\u4e2d\u7684\u6570\u636e\u683c\u5f0f\u4e0eMATLAB\u652f\u6301\u7684\u683c\u5f0f\u517c\u5bb9\u3002\u7279\u522b\u662f\u6570\u636e\u7684\u7ef4\u5ea6\u548c\u7c7b\u578b\uff0cMATLAB\u901a\u5e38\u652f\u6301\u6570\u503c\u77e9\u9635\u3001\u6570\u7ec4\u6216\u7ed3\u6784\u4f53\u3002\u5982\u679ctxt\u6587\u4ef6\u4e2d\u5305\u542b\u975e\u6570\u503c\u6570\u636e\uff08\u5982\u5b57\u7b26\u4e32\uff09\uff0c\u5728\u8f6c\u6362\u65f6\u53ef\u80fd\u9700\u8981\u8fdb\u884c\u9884\u5904\u7406\uff0c\u786e\u4fdd\u6570\u636e\u683c\u5f0f\u6b63\u786e\u3002<\/p>\n<p><strong>\u4f7f\u7528Python\u5c06\u6570\u636e\u4fdd\u5b58\u4e3amat\u6587\u4ef6\u7684\u6700\u4f73\u65b9\u6cd5\u662f\u4ec0\u4e48\uff1f<\/strong><br \/>\u53ef\u4ee5\u4f7f\u7528<code>scipy.io<\/code>\u6a21\u5757\u4e2d\u7684<code>savemat()<\/code>\u51fd\u6570\u5c06\u6570\u636e\u4fdd\u5b58\u4e3amat\u6587\u4ef6\u3002\u8be5\u51fd\u6570\u652f\u6301\u5c06numpy\u6570\u7ec4\u6216\u5b57\u5178\u5bf9\u8c61\u8f6c\u6362\u4e3aMATLAB\u683c\u5f0f\u3002\u5728\u4fdd\u5b58\u4e4b\u524d\uff0c\u5efa\u8bae\u5c06\u6570\u636e\u7ec4\u7ec7\u6210\u9002\u5408MATLAB\u4f7f\u7528\u7684\u683c\u5f0f\uff0c\u786e\u4fdd\u4fdd\u5b58\u540e\u7684mat\u6587\u4ef6\u80fd\u591f\u88abMATLAB\u987a\u5229\u8bfb\u53d6\u3002<\/p>\n<p><strong>\u8f6c\u6362\u540e\u5982\u4f55\u5728MATLAB\u4e2d\u9a8c\u8bc1\u6570\u636e\u7684\u6b63\u786e\u6027\uff1f<\/strong><br \/>\u5728MATLAB\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528<code>load<\/code>\u51fd\u6570\u52a0\u8f7dmat\u6587\u4ef6\uff0c\u4e4b\u540e\u53ef\u4ee5\u901a\u8fc7\u67e5\u770b\u53d8\u91cf\u7684\u7ef4\u5ea6\u3001\u7c7b\u578b\u548c\u5185\u5bb9\u6765\u9a8c\u8bc1\u6570\u636e\u7684\u6b63\u786e\u6027\u3002\u4f7f\u7528<code>whos<\/code>\u547d\u4ee4\u53ef\u4ee5\u5217\u51fa\u5f53\u524d\u5de5\u4f5c\u7a7a\u95f4\u4e2d\u7684\u6240\u6709\u53d8\u91cf\u53ca\u5176\u5c5e\u6027\uff0c\u786e\u4fdd\u6570\u636e\u7b26\u5408\u9884\u671f\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"\u4f7f\u7528Python\u5c06txt\u8f6c\u6362\u4e3amat\u6587\u4ef6\u7684\u5173\u952e\u6b65\u9aa4\u5305\u62ec\uff1a\u8bfb\u53d6txt\u6587\u4ef6\u3001\u5904\u7406\u6570\u636e\u3001\u5c06\u6570\u636e\u5199\u5165mat\u6587\u4ef6\u3002 \u6b65\u9aa4 [&hellip;]","protected":false},"author":3,"featured_media":1033590,"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\/1033587"}],"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=1033587"}],"version-history":[{"count":"1","href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1033587\/revisions"}],"predecessor-version":[{"id":1033591,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1033587\/revisions\/1033591"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/1033590"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=1033587"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=1033587"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=1033587"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}