{"id":202897,"date":"2023-08-05T04:46:27","date_gmt":"2023-08-04T20:46:27","guid":{"rendered":"https:\/\/www.idc.net\/help\/202897\/"},"modified":"2023-08-05T04:46:27","modified_gmt":"2023-08-04T20:46:27","slug":"pytorch-1-9%e5%8f%91%e5%b8%83%ef%bc%81%e7%a7%bb%e5%8a%a8%e7%ab%af%e7%96%af%e7%8b%82%e6%9b%b4%e6%96%b0%ef%bc%8c%e7%bd%91%e5%8f%8b%ef%bc%9a%e6%88%91%e7%9a%84%e6%9c%80%e7%88%b1","status":"publish","type":"post","link":"https:\/\/idc.net\/help\/202897\/","title":{"rendered":"PyTorch 1.9\u53d1\u5e03\uff01\u79fb\u52a8\u7aef\u75af\u72c2\u66f4\u65b0\uff0c\u7f51\u53cb\uff1a\u6211\u7684\u6700\u7231"},"content":{"rendered":"<p style=\"text-align: center\">&nbsp;<span>[[405980]]<\/span><\/p>\n<p>\u672c\u6587\u7ecfAI\u65b0\u5a92\u4f53\u91cf\u5b50\u4f4d\uff08\u516c\u4f17\u53f7ID:QbitAI\uff09\u6388\u6743\u8f6c\u8f7d\uff0c\u8f6c\u8f7d\u8bf7\u8054\u7cfb\u51fa\u5904\u3002<\/p>\n<p>\u65f6\u9694\u4ec53\u4e2a\u6708\uff0c<strong>PyTorch<\/strong>\u518d\u6b21\u8fce\u6765\u5347\u7ea7\u2014\u2014<strong>1.9\u7248\u672c<\/strong>\u3002<\/p>\n<p>\u8fd9\u4e00\u6b21\uff0c\u5b98\u65b9\u628a\u91cd\u5934\u620f\u653e\u5728\u4e86<strong>\u79fb\u52a8\u7aef<\/strong>\u4e0a\u3002<\/p>\n<p>\u4e0d\u4ec5Mobile Interpreter\u53d1\u5e03\u4e86\u65b0\u7248\u672c\uff0c\u800c\u4e14TorchVision\u5e93\u4e5f\u652f\u6301\u5728\u624b\u673a\u4e0a\u4f7f\u7528\u4e86\uff0ciOS\u3001Android\u90fd\u652f\u6301\uff01<\/p>\n<p>\u7f51\u53cb\u770b\u4e86\u90fd\u8868\u793a\uff1a<\/p>\n<blockquote>\n<p>\u8fd9\u4e00\u6b21\u66f4\u65b0\u4e2d\uff0c\u6211\u5bf9\u79fb\u52a8\u7aef\u6700\u611f\u5174\u8da3\u3002<\/p>\n<\/blockquote>\n<p>\u800c\u6b64\u6b211.9\u7248\u672c\u96c6\u5408\u4e86\u81ea2021\u5e743\u67081.8\u7248\u672c\u53d1\u5e03\u4ee5\u6765\uff0c\u8d85\u8fc73400\u6b21GitHub\u63d0\u4ea4\u3002<\/p>\n<p>\u9664\u4e86\u79fb\u52a8\u8bbe\u5907\u7aef\u65b9\u9762\uff0c\u8fd8\u6709\u5176\u4ed6\u8bf8\u591a\u4eae\u70b9\uff1a<\/p>\n<ul>\n<li>\u524d\u7aefAPI\u6539\u8fdb\uff08\u5305\u62ectorch.linalg\u3001torch.special\u548c Complex Autograd\uff09<\/li>\n<li>\u5b9e\u73b0\u5bf9\u5f39\u6027\u3001\u5bb9\u9519\u5206\u5e03\u5f0f\u8bad\u7ec3\u7684\u672c\u5730\u652f\u6301<\/li>\n<li>\u66f4\u65b0PyTorch\u6a21\u578b\u6027\u80fd\u5206\u6790\u5668<\/li>\n<\/ul>\n<p>LeCun\u4e5f\u5728Twitter\u4e0a\u7ad9\u53f0\uff0c\u79f0\u8d5ePyTorch\u505a\u7684\u4e00\u6b21\u6bd4\u4e00\u6b21\u597d\uff01<\/p>\n<h3>\u5728\u624b\u673a\u4e0a\u7528TorchVision\u5e93<\/h3>\n<p>\u9996\u5148\u5c31\u662fPyTorch Mobile\u6700\u53d7\u6b22\u8fce\u7684\u529f\u80fd\u4e4b\u4e00<strong>Mobile Interpreter<\/strong>\u66f4\u65b0\u4e86\u3002<\/p>\n<p>\u6700\u65b0\u7248\u672c\u80fd\u591f\u5c06\u79fb\u52a8\u8bbe\u5907\u4e0a\u7684\u4e8c\u8fdb\u5236\u6587\u4ef6\u5927\u5c0f\u964d\u4f4e\u5230\u539f\u6765\u5927\u5c0f\u7684<strong>\u4e00\u534a\u4ee5\u4e0b<\/strong>\u3002<\/p>\n<p>\u6bd4\u5982\uff0c\u5728arm64-v8a\u67b6\u6784\u7684Android\u8bbe\u5907\u4e2d\u4f7f\u7528MobileNetV2\u7684pt\u5927\u5c0f\uff0c\u538b\u7f29\u524d\u4e3a17.8MB\u3001\u538b\u7f29\u540e\u4e3a8.6MB\u3002<\/p>\n<p>\u800c\u4f7f\u7528\u65b0\u7248Mobile Interpreter\u540e\uff0c\u53ef\u4ee5\u628a\u538b\u7f29\u524d\u7684\u6587\u4ef6\u5927\u5c0f\u964d\u4f4e\u52308MB\u4ee5\u4e0b\uff0c\u538b\u7f29\u540e\u7684\u5927\u5c0f\u964d\u4f4e\u52304MB\u4ee5\u4e0b\u3002<\/p>\n<p>\u4e0e\u6b64\u540c\u65f6\uff0c\u4ece1.9\u7248\u672c\u5f00\u59cb\uff0c\u7528\u6237\u53ef\u4ee5\u5728iOS\u3001Android\u7684APP\u4e0a\u4f7f\u7528<strong>TorchVision\u5e93<\/strong>\u4e86\u3002<\/p>\n<p>\u5728iOS\u4e0a\uff0c\u5b83\u9700\u8981\u548c\u4e3b\u8981\u7684PyTorch\u5e93\u94fe\u63a5\u5728\u4e00\u8d77\u4f7f\u7528\uff1b\u5728Android\u4e0a\uff0c\u5219\u53ef\u4f5c\u4e3agradle\u4f9d\u8d56\u9879\u6dfb\u52a0\u3002<\/p>\n<p>\u5728demo APP\u65b9\u9762\uff0c\u8fd9\u4e00\u6b21\u66f4\u65b0\u4e86\u4e00\u4e2a\u65b0\u7684\u57fa\u4e8ePyTorch Video\u5e93\u7684\u89c6\u9891APP\u548c\u4e00\u4e2a\u57fa\u4e8e\u6700\u65b0torchaudio,\u3001wave2vec\u6a21\u578b\u7684\u8bed\u97f3\u8bc6\u522bAPP\u3002<\/p>\n<p>\u6709\u4e86\u8fd9\u4e24\u4e2aAPP\u540e\uff0cPyTorch\u73b0\u5728\u53ef\u4ee5\u63d0\u4f9b\u56fe\u50cf\u3001\u6587\u5b57\u3001\u97f3\u9891\u548c\u89c6\u9891\u5728\u5185\u7684<strong>\u4e00\u6574\u5957<\/strong>demo APP\u3002<\/p>\n<h3>\u524d\u7aefAPI\u6539\u8fdb<\/h3>\n<p>1.9\u7248\u672c\u4e2d\uff0c\u5bf9torch.linalg\u3001torch.special\u548cComplex Autograd\u7b49\u6a21\u5757\u8fdb\u884c\u4e86\u5b8c\u5584\u3002<\/p>\n<p>torch.linalg\u6a21\u5757\u73b0\u5728\u53ef\u4ee5\u5b9e\u73b0NumPy\u7ebf\u6027\u4ee3\u6570\u6a21\u5757\u4e2d\u7684\u6bcf\u4e2a\u51fd\u6570\uff1b<\/p>\n<p>Complex Autograd\u66f4\u65b0\u7684\u65b0\u529f\u80fd\uff0c\u53ef\u4ee5\u8ba1\u7b97\u590d\u6742\u68af\u5ea6\u3001\u4f18\u5316\u635f\u5931\u51fd\u6570\u3002<\/p>\n<p>\u6b64\u5916\uff0c\u4e3a\u4e86\u5e2e\u52a9\u8c03\u8bd5\u548c\u7f16\u5199\u53ef\u91cd\u73b0\u7684\u7a0b\u5e8f\uff0cPyTorch 1.9\u589e\u52a0\u4e86\u4e00\u4e2atorch.use_determinstic_algorithms\u9009\u9879\u3002<\/p>\n<p>\u8fd9\u662f\u4e3a\u4e86\u907f\u514d\u8fd0\u884c\u4e2d\u53ef\u80fd\u4f1a\u51fa\u73b0\u7684\u9519\u8bef\uff0c\u5982\u4e0b\u6240\u793a\uff1a<\/p>\n<h3>\u5206\u5e03\u5f0f\u8bad\u7ec3<\/h3>\n<p>TorchElastic\u662fPyTorch\u7684\u4e00\u4e2a\u6838\u5fc3\u529f\u80fd\uff0c\u5b83\u80fd\u591f\u8ba9\u7528\u6237\u5728\u62a2\u5360\u5f0f\u5b9e\u4f8b\u4e0a\u8fd0\u884c\u5206\u5e03\u5f0f\u8bad\u7ec3\u3002<\/p>\n<p style=\"text-align: center\">\n<p>\u25b3TorchElastic\u8fd0\u884c\u539f\u7406<\/p>\n<p>\u65b0\u7248\u672c\u4e2d\uff0c\u6dfb\u52a0\u4e86\u4e00\u4e2a\u57fa\u4e8ec10d::Store\u7684\u201c\u72ec\u7acb\u201d\u96c6\u5408\u70b9\uff0c\u80fd\u591f\u5728\u672c\u5730\u652f\u6301\u5f39\u6027\u3001\u5bb9\u9519\u5206\u5e03\u5f0f\u8bad\u7ec3\u3002<\/p>\n<p>\u6b64\u5916\uff0c\u73b0\u5728\u8fd8\u53ef\u5728RPC\u4e2d\u652f\u6301CUDA\uff0c\u5e76\u652f\u6301\u5bf9\u5206\u5e03\u5f0f\u8bad\u7ec3\u8fdb\u884c\u5206\u6790\u7b49\u3002<\/p>\n<h3>PyTorch Profiler<\/h3>\n<p>PyTorch Profiler\u662f\u7528\u6765\u5bf9PyTorch\u6a21\u578b\u6027\u80fd\u5206\u6790\u7684\u4e00\u4e2a\u5de5\u5177\u3002<\/p>\n<p>\u901a\u8fc7\u53ef\u89c6\u5316\u9875\u9762\u6765\u5e2e\u52a9\u6211\u4eec\u5206\u6790\u5177\u4f53\u8fd0\u884c\u60c5\u51b5\u3002<\/p>\n<p>\u57281.9\u7248\u672c\u4e2d\uff0c\u53ef\u4ee5\u5728Windows\u548cMac\u4e2d\u652f\u6301\u65b0\u7684torch.profiler API\u4e86\u3002<\/p>\n<p>\u65b0\u7684API\u652f\u6301\u73b0\u6709\u5206\u6790\u5668\u529f\u80fd\uff0c\u53ef\u4ee5\u4e0eCUPTI\u5e93\u96c6\u6210\uff08\u4ec5\u9650Linux\uff09\uff0c\u8ffd\u8e2a\u8bbe\u5907\u4e0a\u7684CUDA\u5185\u6838\uff0c\u5e76\u4e3a\u957f\u671f\u8fd0\u884c\u9879\u76ee\u63d0\u4f9b\u652f\u6301\uff0c\u4f8b\u5982\uff1a<\/p>\n<p>PyTorch Profiler Tensorboard\u63d2\u4ef6\u8fd8\u66f4\u65b0\u4e86\u5e26\u6709NCCL\u7684\u5206\u5e03\u5f0f\u8bad\u7ec3\u6458\u8981\u89c6\u56fe\u3001\u5185\u5b58\u5206\u6790\u89c6\u56fe\u3001\u4eceMicrosoft VSCode\u542f\u52a8\u65f6\u53ef\u8df3\u8f6c\u5230\u6e90\u4ee3\u7801\u7b49\u65b0\u529f\u80fd\u3002<\/p>\n<p>\u66f4\u591a\u66f4\u65b0\u4fe1\u606f\u8bf7\u6233\uff1a<\/p>\n<p>https:\/\/pytorch.org\/blog\/pytorch-1.9-released\/<\/p>\n<p style=\"text-align: center\">\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>&nbsp;[[405980]] \u672c\u6587\u7ecfAI\u65b0\u5a92\u4f53\u91cf\u5b50\u4f4d\uff08\u516c\u4f17\u53f7ID:QbitAI\uff09\u6388\u6743\u8f6c\u8f7d\uff0c\u8f6c\u8f7d\u8bf7\u8054\u7cfb\u51fa\u5904\u3002 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":202898,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[195111],"tags":[],"class_list":["post-202897","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-android"],"_links":{"self":[{"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/posts\/202897","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/comments?post=202897"}],"version-history":[{"count":0,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/posts\/202897\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/media\/202898"}],"wp:attachment":[{"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/media?parent=202897"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/categories?post=202897"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/tags?post=202897"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}