{"id":83056,"date":"2026-07-25T16:10:25","date_gmt":"2026-07-25T08:10:25","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/83056.html"},"modified":"2026-07-25T16:10:25","modified_gmt":"2026-07-25T08:10:25","slug":"frcrn%e9%83%a8%e7%bd%b2%e6%95%99%e7%a8%8b%ef%bc%9a%e4%bd%bf%e7%94%a8nvidia-triton%e6%8e%a8%e7%90%86%e6%9c%8d%e5%8a%a1%e5%99%a8%e7%bb%9f%e4%b8%80%e7%ae%a1%e7%90%86%e5%a4%9a%e6%a8%a1%e5%9e%8b","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/83056.html","title":{"rendered":"FRCRN\u90e8\u7f72\u6559\u7a0b\uff1a\u4f7f\u7528NVIDIA Triton\u63a8\u7406\u670d\u52a1\u5668\u7edf\u4e00\u7ba1\u7406\u591a\u6a21\u578b"},"content":{"rendered":"<h2>FRCRN\u90e8\u7f72\u6559\u7a0b&#xff1a;\u4f7f\u7528NVIDIA Triton\u63a8\u7406\u670d\u52a1\u5668\u7edf\u4e00\u7ba1\u7406\u591a\u6a21\u578b<\/h2>\n<p>\u4f60\u662f\u4e0d\u662f\u4e5f\u9047\u5230\u8fc7\u8fd9\u6837\u7684\u70e6\u607c&#xff1f;\u56e2\u961f\u91cc\u90e8\u7f72\u4e86\u597d\u51e0\u4e2aAI\u6a21\u578b&#xff0c;\u6bcf\u4e2a\u6a21\u578b\u90fd\u6709\u81ea\u5df1\u7684\u73af\u5883\u4f9d\u8d56\u3001\u542f\u52a8\u811a\u672c\u548cAPI\u63a5\u53e3&#xff0c;\u7ba1\u7406\u8d77\u6765\u50cf\u4e00\u76d8\u6563\u6c99\u3002\u4eca\u5929\u8981\u90e8\u7f72\u4e00\u4e2a\u8bed\u97f3\u964d\u566a\u6a21\u578b&#xff0c;\u660e\u5929\u8981\u4e0a\u7ebf\u4e00\u4e2a\u56fe\u50cf\u8bc6\u522b\u670d\u52a1&#xff0c;\u540e\u5929\u53ef\u80fd\u53c8\u8981\u52a0\u4e00\u4e2a\u6587\u672c\u751f\u6210\u5de5\u5177\u3002\u6bcf\u6b21\u90fd\u8981\u5355\u72ec\u914d\u7f6e&#xff0c;\u4e0d\u4ec5\u6548\u7387\u4f4e\u4e0b&#xff0c;\u8fd8\u5bb9\u6613\u51fa\u9519\u3002<\/p>\n<p>\u5982\u679c\u4f60\u6b63\u5728\u4e3a\u591a\u6a21\u578b\u7ba1\u7406\u5934\u75bc&#xff0c;\u90a3\u4e48NVIDIA Triton\u63a8\u7406\u670d\u52a1\u5668\u53ef\u80fd\u5c31\u662f\u4f60\u7684\u6551\u661f\u3002\u5b83\u5c31\u50cf\u4e00\u4e2a\u201cAI\u6a21\u578b\u7ba1\u5bb6\u201d&#xff0c;\u80fd\u628a\u4e0d\u540c\u6846\u67b6\u3001\u4e0d\u540c\u7248\u672c\u7684\u6a21\u578b\u7edf\u4e00\u7ba1\u7406\u8d77\u6765&#xff0c;\u63d0\u4f9b\u6807\u51c6\u5316\u7684\u670d\u52a1\u63a5\u53e3\u3002<\/p>\n<p>\u4eca\u5929&#xff0c;\u6211\u5c31\u624b\u628a\u624b\u5e26\u4f60\u7528Triton\u6765\u90e8\u7f72\u4e00\u4e2a\u975e\u5e38\u5b9e\u7528\u7684\u8bed\u97f3\u964d\u566a\u6a21\u578b\u2014\u2014FRCRN\u3002\u8fd9\u4e2a\u6a21\u578b\u6765\u81ea\u963f\u91cc\u5df4\u5df4\u8fbe\u6469\u9662&#xff0c;\u4e13\u95e8\u5904\u7406\u5355\u901a\u9053\u97f3\u9891\u7684\u566a\u58f0\u6d88\u9664&#xff0c;\u6548\u679c\u76f8\u5f53\u4e0d\u9519\u3002\u66f4\u91cd\u8981\u7684\u662f&#xff0c;\u901a\u8fc7\u8fd9\u6b21\u5b9e\u8df5&#xff0c;\u4f60\u80fd\u638c\u63e1\u7528Triton\u7ba1\u7406\u4efb\u610f\u6a21\u578b\u7684\u65b9\u6cd5\u3002<\/p>\n<h3>1. \u4e3a\u4ec0\u4e48\u9009\u62e9Triton &#043; FRCRN&#xff1f;<\/h3>\n<p>\u5728\u5f00\u59cb\u52a8\u624b\u4e4b\u524d&#xff0c;\u6211\u4eec\u5148\u641e\u6e05\u695a\u4e24\u4e2a\u95ee\u9898&#xff1a;\u4e3a\u4ec0\u4e48\u8981\u7528Triton&#xff1f;\u4e3a\u4ec0\u4e48\u8981\u90e8\u7f72FRCRN&#xff1f;<\/p>\n<h4>1.1 Triton\u63a8\u7406\u670d\u52a1\u5668\u7684\u4f18\u52bf<\/h4>\n<p>\u60f3\u8c61\u4e00\u4e0b&#xff0c;\u5982\u679c\u6ca1\u6709Triton&#xff0c;\u4f60\u7684AI\u670d\u52a1\u90e8\u7f72\u6d41\u7a0b\u53ef\u80fd\u662f\u8fd9\u6837\u7684&#xff1a;<\/p>\n<li>\u4e3a\u6bcf\u4e2a\u6a21\u578b\u5355\u72ec\u51c6\u5907\u4e00\u4e2aDocker\u5bb9\u5668<\/li>\n<li>\u5728\u6bcf\u4e2a\u5bb9\u5668\u91cc\u5b89\u88c5\u4e0d\u540c\u7684\u4f9d\u8d56\u5305<\/li>\n<li>\u4e3a\u6bcf\u4e2a\u6a21\u578b\u7f16\u5199\u4e0d\u540c\u7684API\u670d\u52a1\u4ee3\u7801<\/li>\n<li>\u5206\u522b\u914d\u7f6e\u7aef\u53e3\u3001\u65e5\u5fd7\u3001\u76d1\u63a7<\/li>\n<li>\u624b\u52a8\u7ba1\u7406\u6a21\u578b\u7684\u7248\u672c\u66f4\u65b0<\/li>\n<p>\u6709\u4e86Triton\u4e4b\u540e&#xff0c;\u6d41\u7a0b\u5c31\u7b80\u5316\u591a\u4e86&#xff1a;<\/p>\n<ul>\n<li>\u7edf\u4e00\u7ba1\u7406&#xff1a;\u6240\u6709\u6a21\u578b\u90fd\u653e\u5728Triton\u7684\u6a21\u578b\u4ed3\u5e93\u91cc<\/li>\n<li>\u6807\u51c6\u63a5\u53e3&#xff1a;\u901a\u8fc7HTTP\u6216gRPC\u63d0\u4f9b\u7edf\u4e00\u7684\u63a8\u7406\u670d\u52a1<\/li>\n<li>\u81ea\u52a8\u6279\u5904\u7406&#xff1a;Triton\u80fd\u667a\u80fd\u5408\u5e76\u591a\u4e2a\u8bf7\u6c42&#xff0c;\u63d0\u9ad8GPU\u5229\u7528\u7387<\/li>\n<li>\u591a\u6846\u67b6\u652f\u6301&#xff1a;PyTorch\u3001TensorFlow\u3001ONNX\u7b49\u6846\u67b6\u7684\u6a21\u578b\u90fd\u80fd\u6258\u7ba1<\/li>\n<li>\u52a8\u6001\u52a0\u8f7d&#xff1a;\u6dfb\u52a0\u65b0\u6a21\u578b\u65e0\u9700\u91cd\u542f\u670d\u52a1<\/li>\n<\/ul>\n<h4>1.2 FRCRN\u6a21\u578b\u7b80\u4ecb<\/h4>\n<p>FRCRN&#xff08;Frequency-Recurrent Convolutional Recurrent Network&#xff09;\u662f\u963f\u91cc\u5df4\u5df4\u8fbe\u6469\u9662\u5f00\u6e90\u7684\u8bed\u97f3\u964d\u566a\u6a21\u578b&#xff0c;\u5728ModelScope\u793e\u533a\u53ef\u4ee5\u76f4\u63a5\u4f7f\u7528\u3002\u5b83\u7684\u7279\u70b9\u662f&#xff1a;<\/p>\n<ul>\n<li>\u4e13\u653b\u5355\u901a\u9053&#xff1a;\u9488\u5bf9\u5355\u9ea6\u514b\u98ce\u5f55\u97f3\u573a\u666f\u4f18\u5316<\/li>\n<li>\u5f3a\u964d\u566a\u80fd\u529b&#xff1a;\u80fd\u6709\u6548\u6d88\u9664\u5404\u79cd\u80cc\u666f\u566a\u58f0<\/li>\n<li>\u4fdd\u771f\u5ea6\u9ad8&#xff1a;\u5728\u964d\u566a\u7684\u540c\u65f6\u5c3d\u91cf\u4fdd\u7559\u4eba\u58f0\u7ec6\u8282<\/li>\n<li>16kHz\u91c7\u6837\u7387&#xff1a;\u9002\u7528\u4e8e\u5927\u591a\u6570\u8bed\u97f3\u573a\u666f<\/li>\n<\/ul>\n<p>\u8fd9\u4e2a\u6a21\u578b\u7279\u522b\u9002\u5408\u7528\u5728&#xff1a;<\/p>\n<ul>\n<li>\u5728\u7ebf\u4f1a\u8bae\u7cfb\u7edf\u7684\u8bed\u97f3\u589e\u5f3a<\/li>\n<li>\u64ad\u5ba2\u6216\u89c6\u9891\u7684\u540e\u671f\u5904\u7406<\/li>\n<li>\u8bed\u97f3\u8bc6\u522b\u7cfb\u7edf\u7684\u524d\u7f6e\u5904\u7406<\/li>\n<li>\u5ba2\u670d\u5f55\u97f3\u7684\u8d28\u91cf\u63d0\u5347<\/li>\n<\/ul>\n<h3>2. \u73af\u5883\u51c6\u5907\u4e0eTriton\u5b89\u88c5<\/h3>\n<p>\u597d\u4e86&#xff0c;\u7406\u8bba\u8bf4\u5b8c\u4e86&#xff0c;\u54b1\u4eec\u5f00\u59cb\u52a8\u624b\u3002\u9996\u5148\u5f97\u628aTriton\u88c5\u8d77\u6765\u3002<\/p>\n<h4>2.1 \u7cfb\u7edf\u8981\u6c42<\/h4>\n<p>\u5728\u5f00\u59cb\u4e4b\u524d&#xff0c;\u786e\u8ba4\u4f60\u7684\u73af\u5883\u6ee1\u8db3\u4ee5\u4e0b\u8981\u6c42&#xff1a;<\/p>\n<ul>\n<li>\u64cd\u4f5c\u7cfb\u7edf&#xff1a;Ubuntu 18.04\/20.04\/22.04&#xff08;\u5176\u4ed6Linux\u53d1\u884c\u7248\u4e5f\u53ef\u4ee5&#xff0c;\u4f46Ubuntu\u6700\u7701\u5fc3&#xff09;<\/li>\n<li>Docker&#xff1a;19.03\u6216\u66f4\u9ad8\u7248\u672c<\/li>\n<li>NVIDIA GPU&#xff1a;\u81f3\u5c118GB\u663e\u5b58&#xff08;Triton\u4e5f\u652f\u6301CPU\u6a21\u5f0f&#xff0c;\u4f46GPU\u6027\u80fd\u597d\u592a\u591a&#xff09;<\/li>\n<li>NVIDIA\u9a71\u52a8&#xff1a;470.x\u6216\u66f4\u9ad8\u7248\u672c<\/li>\n<li>CUDA&#xff1a;11.0\u6216\u66f4\u9ad8\u7248\u672c<\/li>\n<\/ul>\n<p>\u5982\u679c\u4f60\u7528\u7684\u662f\u4e91\u670d\u52a1\u5668&#xff0c;\u8fd9\u4e9b\u901a\u5e38\u90fd\u5df2\u7ecf\u9884\u88c5\u597d\u4e86\u3002\u672c\u5730\u73af\u5883\u7684\u8bdd&#xff0c;\u53ef\u4ee5\u8fd0\u884c\u4ee5\u4e0b\u547d\u4ee4\u68c0\u67e5&#xff1a;<\/p>\n<p># \u68c0\u67e5Docker\u7248\u672c<br \/>\ndocker &#8211;version<\/p>\n<p># \u68c0\u67e5NVIDIA\u9a71\u52a8<br \/>\nnvidia-smi<\/p>\n<p># \u68c0\u67e5CUDA\u7248\u672c<br \/>\nnvcc &#8211;version<\/p>\n<h4>2.2 \u5b89\u88c5NVIDIA Container Toolkit<\/h4>\n<p>Triton\u9700\u8981Docker\u80fd\u591f\u8bbf\u95eeGPU&#xff0c;\u6240\u4ee5\u8981\u5148\u5b89\u88c5NVIDIA Container Toolkit&#xff1a;<\/p>\n<p># \u6dfb\u52a0NVIDIA\u7684\u5305\u4ed3\u5e93<br \/>\ndistribution&#061;$(. \/etc\/os-release;echo $ID$VERSION_ID)<br \/>\ncurl -s -L https:\/\/nvidia.github.io\/nvidia-docker\/gpgkey | sudo apt-key add &#8211;<br \/>\ncurl -s -L https:\/\/nvidia.github.io\/nvidia-docker\/$distribution\/nvidia-docker.list | sudo tee \/etc\/apt\/sources.list.d\/nvidia-docker.list<\/p>\n<p># \u5b89\u88c5\u5de5\u5177\u5305<br \/>\nsudo apt-get update<br \/>\nsudo apt-get install -y nvidia-docker2<\/p>\n<p># \u91cd\u542fDocker\u670d\u52a1<br \/>\nsudo systemctl restart docker<\/p>\n<p>\u5b89\u88c5\u5b8c\u6210\u540e&#xff0c;\u6d4b\u8bd5\u4e00\u4e0bGPU\u5728Docker\u4e2d\u662f\u5426\u53ef\u7528&#xff1a;<\/p>\n<p># \u8fd0\u884c\u4e00\u4e2a\u6d4b\u8bd5\u5bb9\u5668<br \/>\nsudo docker run &#8211;rm &#8211;gpus all nvidia\/cuda:11.0-base nvidia-smi<\/p>\n<p>\u5982\u679c\u80fd\u770b\u5230GPU\u4fe1\u606f&#xff0c;\u8bf4\u660e\u914d\u7f6e\u6210\u529f\u4e86\u3002<\/p>\n<h4>2.3 \u62c9\u53d6Triton\u670d\u52a1\u5668\u955c\u50cf<\/h4>\n<p>Triton\u63d0\u4f9b\u4e86\u591a\u4e2a\u7248\u672c\u7684\u955c\u50cf&#xff0c;\u6211\u4eec\u9009\u62e9\u5305\u542bPyTorch\u540e\u7aef\u7684\u7248\u672c&#xff0c;\u56e0\u4e3aFRCRN\u662fPyTorch\u6a21\u578b&#xff1a;<\/p>\n<p># \u62c9\u53d6Triton\u670d\u52a1\u5668\u955c\u50cf<br \/>\ndocker pull nvcr.io\/nvidia\/tritonserver:22.12-py3<\/p>\n<p># \u8fd9\u4e2a\u955c\u50cf\u6bd4\u8f83\u5927&#xff0c;\u7ea610GB&#xff0c;\u9700\u8981\u8010\u5fc3\u7b49\u5f85<br \/>\n# \u5982\u679c\u4e0b\u8f7d\u6162&#xff0c;\u53ef\u4ee5\u914d\u7f6eDocker\u955c\u50cf\u52a0\u901f<\/p>\n<p>\u8fd9\u4e2a\u955c\u50cf\u5305\u542b\u4e86&#xff1a;<\/p>\n<ul>\n<li>Triton\u63a8\u7406\u670d\u52a1\u5668<\/li>\n<li>PyTorch\u540e\u7aef\u652f\u6301<\/li>\n<li>Python\u5ba2\u6237\u7aef\u5e93<\/li>\n<li>\u5404\u79cd\u5de5\u5177\u548c\u793a\u4f8b<\/li>\n<\/ul>\n<h3>3. \u51c6\u5907FRCRN\u6a21\u578b<\/h3>\n<p>Triton\u9700\u8981\u6a21\u578b\u6309\u7167\u7279\u5b9a\u7684\u76ee\u5f55\u7ed3\u6784\u6765\u7ec4\u7ec7&#xff0c;\u6240\u4ee5\u6211\u4eec\u8981\u5148\u628aFRCRN\u6a21\u578b\u201c\u5305\u88c5\u201d\u6210Triton\u80fd\u8bc6\u522b\u7684\u683c\u5f0f\u3002<\/p>\n<h4>3.1 \u521b\u5efa\u6a21\u578b\u76ee\u5f55\u7ed3\u6784<\/h4>\n<p>\u9996\u5148&#xff0c;\u521b\u5efa\u4e00\u4e2a\u5de5\u4f5c\u76ee\u5f55&#xff0c;\u7136\u540e\u6309\u7167Triton\u7684\u8981\u6c42\u7ec4\u7ec7\u6587\u4ef6&#xff1a;<\/p>\n<p># \u521b\u5efa\u5de5\u4f5c\u76ee\u5f55<br \/>\nmkdir -p ~\/triton_models<br \/>\ncd ~\/triton_models<\/p>\n<p># \u521b\u5efaFRCRN\u6a21\u578b\u7684\u76ee\u5f55\u7ed3\u6784<br \/>\nmkdir -p frcrn\/1<br \/>\nmkdir -p frcrn\/config<\/p>\n<p>Triton\u7684\u6a21\u578b\u76ee\u5f55\u7ed3\u6784\u662f\u8fd9\u6837\u7684&#xff1a;<\/p>\n<p>frcrn\/              # \u6a21\u578b\u540d\u79f0<br \/>\n\u251c\u2500\u2500 1\/              # \u7248\u672c\u53f7&#xff08;\u5fc5\u987b\u662f\u6570\u5b57&#xff09;<br \/>\n\u2502   \u2514\u2500\u2500 model.py    # \u6a21\u578b\u63a8\u7406\u811a\u672c<br \/>\n\u2514\u2500\u2500 config.pbtxt    # \u6a21\u578b\u914d\u7f6e\u6587\u4ef6<\/p>\n<h4>3.2 \u7f16\u5199\u6a21\u578b\u914d\u7f6e\u6587\u4ef6<\/h4>\n<p>\u5728frcrn\/config.pbtxt\u4e2d&#xff0c;\u6211\u4eec\u9700\u8981\u544a\u8bc9Triton\u8fd9\u4e2a\u6a21\u578b\u7684\u57fa\u672c\u4fe1\u606f&#xff1a;<\/p>\n<p>name: &#034;frcrn&#034;<br \/>\nplatform: &#034;pytorch_libtorch&#034;<br \/>\nmax_batch_size: 8<\/p>\n<p>input [<br \/>\n  {<br \/>\n    name: &#034;audio_input&#034;<br \/>\n    data_type: TYPE_FP32<br \/>\n    dims: [ -1, 1 ]  # \u52a8\u6001\u7ef4\u5ea6&#xff0c;\u652f\u6301\u4e0d\u540c\u957f\u5ea6\u7684\u97f3\u9891<br \/>\n  }<br \/>\n]<\/p>\n<p>output [<br \/>\n  {<br \/>\n    name: &#034;audio_output&#034;<br \/>\n    data_type: TYPE_FP32<br \/>\n    dims: [ -1, 1 ]  # \u8f93\u51fa\u4e0e\u8f93\u5165\u76f8\u540c\u957f\u5ea6<br \/>\n  }<br \/>\n]<\/p>\n<p>instance_group [<br \/>\n  {<br \/>\n    count: 1<br \/>\n    kind: KIND_GPU<br \/>\n  }<br \/>\n]<\/p>\n<p>parameters [<br \/>\n  {<br \/>\n    key: &#034;sampling_rate&#034;<br \/>\n    value: { string_value: &#034;16000&#034; }<br \/>\n  }<br \/>\n]<\/p>\n<p>\u8fd9\u4e2a\u914d\u7f6e\u6587\u4ef6\u5b9a\u4e49\u4e86&#xff1a;<\/p>\n<ul>\n<li>\u6a21\u578b\u540d\u79f0&#xff1a;frcrn<\/li>\n<li>\u4f7f\u7528\u5e73\u53f0&#xff1a;PyTorch<\/li>\n<li>\u6700\u5927\u6279\u5904\u7406\u5927\u5c0f&#xff1a;8&#xff08;\u53ef\u4ee5\u540c\u65f6\u5904\u74068\u4e2a\u97f3\u9891&#xff09;<\/li>\n<li>\u8f93\u5165\u8f93\u51fa\u683c\u5f0f&#xff1a;\u5355\u7cbe\u5ea6\u6d6e\u70b9\u6570\u7684\u97f3\u9891\u6570\u636e<\/li>\n<li>\u5b9e\u4f8b\u914d\u7f6e&#xff1a;\u4f7f\u75281\u4e2aGPU\u5b9e\u4f8b<\/li>\n<li>\u53c2\u6570&#xff1a;\u91c7\u6837\u7387\u56fa\u5b9a\u4e3a16000Hz<\/li>\n<\/ul>\n<h4>3.3 \u7f16\u5199\u6a21\u578b\u63a8\u7406\u811a\u672c<\/h4>\n<p>\u8fd9\u662f\u6700\u5173\u952e\u7684\u4e00\u6b65&#xff0c;\u6211\u4eec\u9700\u8981\u5728frcrn\/1\/model.py\u4e2d\u5b9e\u73b0\u6a21\u578b\u7684\u52a0\u8f7d\u548c\u63a8\u7406\u903b\u8f91&#xff1a;<\/p>\n<p>import torch<br \/>\nimport torch.nn as nn<br \/>\nimport numpy as np<br \/>\nfrom typing import Dict, List<br \/>\nimport triton_python_backend_utils as pb_utils<\/p>\n<p>class FRCRNModel(nn.Module):<br \/>\n    &#034;&#034;&#034;FRCRN\u6a21\u578b\u5c01\u88c5\u7c7b&#034;&#034;&#034;<\/p>\n<p>    def __init__(self):<br \/>\n        super(FRCRNModel, self).__init__()<br \/>\n        # \u8fd9\u91cc\u7b80\u5316\u4e86\u6a21\u578b\u7ed3\u6784&#xff0c;\u5b9e\u9645\u4f7f\u7528\u65f6\u9700\u8981\u5bfc\u5165\u5b8c\u6574\u7684FRCRN\u6a21\u578b<br \/>\n        # \u4e3a\u4e86\u6559\u7a0b\u6e05\u6670&#xff0c;\u6211\u4eec\u5148\u4f7f\u7528\u4e00\u4e2a\u7b80\u5355\u7684\u964d\u566a\u7f51\u7edc<br \/>\n        self.conv1 &#061; nn.Conv1d(1, 16, kernel_size&#061;3, padding&#061;1)<br \/>\n        self.conv2 &#061; nn.Conv1d(16, 1, kernel_size&#061;3, padding&#061;1)<br \/>\n        self.relu &#061; nn.ReLU()<\/p>\n<p>    def forward(self, x):<br \/>\n        # \u7b80\u5355\u7684\u964d\u566a\u5904\u7406&#xff1a;\u4e24\u5c42\u5377\u79ef<br \/>\n        x &#061; self.conv1(x)<br \/>\n        x &#061; self.relu(x)<br \/>\n        x &#061; self.conv2(x)<br \/>\n        return x<\/p>\n<p>class TritonPythonModel:<br \/>\n    &#034;&#034;&#034;Triton Python\u540e\u7aef\u6a21\u578b\u7c7b&#034;&#034;&#034;<\/p>\n<p>    def initialize(self, args):<br \/>\n        &#034;&#034;&#034;\u6a21\u578b\u521d\u59cb\u5316&#034;&#034;&#034;<br \/>\n        self.logger &#061; pb_utils.Logger<br \/>\n        self.model &#061; FRCRNModel()<\/p>\n<p>        # \u52a0\u8f7d\u9884\u8bad\u7ec3\u6743\u91cd&#xff08;\u8fd9\u91cc\u9700\u8981\u66ff\u6362\u4e3a\u5b9e\u9645\u7684FRCRN\u6743\u91cd\u8def\u5f84&#xff09;<br \/>\n        # checkpoint &#061; torch.load(&#039;frcrn_weights.pth&#039;)<br \/>\n        # self.model.load_state_dict(checkpoint)<\/p>\n<p>        self.model.eval()<br \/>\n        self.logger.log_info(&#034;FRCRN\u6a21\u578b\u521d\u59cb\u5316\u5b8c\u6210&#034;)<\/p>\n<p>    def execute(self, requests):<br \/>\n        &#034;&#034;&#034;\u5904\u7406\u63a8\u7406\u8bf7\u6c42&#034;&#034;&#034;<br \/>\n        responses &#061; []<\/p>\n<p>        for request in requests:<br \/>\n            # \u83b7\u53d6\u8f93\u5165\u6570\u636e<br \/>\n            audio_input &#061; pb_utils.get_input_tensor_by_name(request, &#034;audio_input&#034;)<br \/>\n            audio_data &#061; audio_input.as_numpy()<\/p>\n<p>            # \u8f6c\u6362\u4e3aPyTorch\u5f20\u91cf<br \/>\n            audio_tensor &#061; torch.from_numpy(audio_data).float()<\/p>\n<p>            # \u6267\u884c\u63a8\u7406<br \/>\n            with torch.no_grad():<br \/>\n                # \u6dfb\u52a0\u6279\u6b21\u7ef4\u5ea6&#xff08;\u5982\u679c\u9700\u8981&#xff09;<br \/>\n                if len(audio_tensor.shape) &#061;&#061; 1:<br \/>\n                    audio_tensor &#061; audio_tensor.unsqueeze(0).unsqueeze(0)<br \/>\n                elif len(audio_tensor.shape) &#061;&#061; 2:<br \/>\n                    audio_tensor &#061; audio_tensor.unsqueeze(1)<\/p>\n<p>                # \u6a21\u578b\u63a8\u7406<br \/>\n                output_tensor &#061; self.model(audio_tensor)<\/p>\n<p>                # \u79fb\u9664\u6279\u6b21\u7ef4\u5ea6<br \/>\n                output_tensor &#061; output_tensor.squeeze()<br \/>\n                if len(output_tensor.shape) &#061;&#061; 1:<br \/>\n                    output_tensor &#061; output_tensor.unsqueeze(0)<\/p>\n<p>            # \u521b\u5efa\u8f93\u51fa\u5f20\u91cf<br \/>\n            output_numpy &#061; output_tensor.numpy()<br \/>\n            output_tensor &#061; pb_utils.Tensor(&#034;audio_output&#034;, output_numpy)<\/p>\n<p>            # \u521b\u5efa\u54cd\u5e94<br \/>\n            response &#061; pb_utils.InferenceResponse(output_tensors&#061;[output_tensor])<br \/>\n            responses.append(response)<\/p>\n<p>        return responses<\/p>\n<p>    def finalize(self):<br \/>\n        &#034;&#034;&#034;\u6e05\u7406\u8d44\u6e90&#034;&#034;&#034;<br \/>\n        self.logger.log_info(&#034;FRCRN\u6a21\u578b\u6e05\u7406\u5b8c\u6210&#034;)<\/p>\n<p>\u91cd\u8981\u8bf4\u660e&#xff1a;\u4e0a\u9762\u7684\u4ee3\u7801\u662f\u4e00\u4e2a\u7b80\u5316\u7248\u672c&#xff0c;\u7528\u4e8e\u6f14\u793aTriton\u6a21\u578b\u7684\u57fa\u672c\u7ed3\u6784\u3002\u5b9e\u9645\u90e8\u7f72FRCRN\u65f6&#xff0c;\u4f60\u9700\u8981&#xff1a;<\/p>\n<li>\u4eceModelScope\u4e0b\u8f7d\u5b8c\u6574\u7684FRCRN\u6a21\u578b<\/li>\n<li>\u5b9e\u73b0\u771f\u5b9e\u7684FRCRN\u7f51\u7edc\u7ed3\u6784<\/li>\n<li>\u52a0\u8f7d\u9884\u8bad\u7ec3\u6743\u91cd<\/li>\n<li>\u6dfb\u52a0\u97f3\u9891\u9884\u5904\u7406\u548c\u540e\u5904\u7406\u903b\u8f91<\/li>\n<h4>3.4 \u51c6\u5907\u771f\u5b9eFRCRN\u6a21\u578b<\/h4>\n<p>\u5982\u679c\u4f60\u8981\u90e8\u7f72\u771f\u5b9e\u7684FRCRN\u6a21\u578b&#xff0c;\u53ef\u4ee5\u8fd9\u6837\u51c6\u5907&#xff1a;<\/p>\n<p># \u5b89\u88c5ModelScope<br \/>\npip install modelscope torchaudio<\/p>\n<p># \u4e0b\u8f7dFRCRN\u6a21\u578b<br \/>\nfrom modelscope.pipelines import pipeline<br \/>\nfrom modelscope.utils.constant import Tasks<\/p>\n<p># \u521b\u5efa\u8bed\u97f3\u964d\u566apipeline<br \/>\nans_pipeline &#061; pipeline(<br \/>\n    task&#061;Tasks.acoustic_noise_suppression,<br \/>\n    model&#061;&#039;damo\/speech_frcrn_ans_cirm_16k&#039;<br \/>\n)<\/p>\n<p># \u4fdd\u5b58\u4e3aTorchScript\u683c\u5f0f&#xff08;Triton\u9700\u8981&#xff09;<br \/>\ndummy_input &#061; torch.randn(1, 1, 16000)  # 1\u79d2\u7684\u97f3\u9891<br \/>\ntraced_model &#061; torch.jit.trace(ans_pipeline.model, dummy_input)<br \/>\ntraced_model.save(&#034;frcrn_model.pt&#034;)<\/p>\n<p>\u7136\u540e\u628a\u4fdd\u5b58\u7684frcrn_model.pt\u653e\u5230\u6a21\u578b\u76ee\u5f55\u4e2d&#xff0c;\u5e76\u4fee\u6539model.py\u6765\u52a0\u8f7d\u8fd9\u4e2a\u6a21\u578b\u3002<\/p>\n<h3>4. \u542f\u52a8Triton\u670d\u52a1\u5668<\/h3>\n<p>\u6a21\u578b\u51c6\u5907\u597d\u4e86&#xff0c;\u73b0\u5728\u53ef\u4ee5\u542f\u52a8Triton\u670d\u52a1\u5668\u4e86\u3002<\/p>\n<h4>4.1 \u542f\u52a8\u547d\u4ee4<\/h4>\n<p># \u542f\u52a8Triton\u670d\u52a1\u5668<br \/>\ndocker run &#8211;gpus&#061;all &#8211;rm \\\\<br \/>\n  -p 8000:8000 -p 8001:8001 -p 8002:8002 \\\\<br \/>\n  -v ~\/triton_models:\/models \\\\<br \/>\n  nvcr.io\/nvidia\/tritonserver:22.12-py3 \\\\<br \/>\n  tritonserver &#8211;model-repository&#061;\/models<\/p>\n<p>\u8fd9\u4e2a\u547d\u4ee4\u505a\u4e86\u51e0\u4ef6\u4e8b&#xff1a;<\/p>\n<ul>\n<li>&#8211;gpus&#061;all&#xff1a;\u8ba9\u5bb9\u5668\u80fd\u8bbf\u95ee\u6240\u6709GPU<\/li>\n<li>-p 8000:8000&#xff1a;HTTP\u7aef\u53e3&#xff08;\u7528\u4e8e\u5065\u5eb7\u68c0\u67e5&#xff09;<\/li>\n<li>-p 8001:8001&#xff1a;gRPC\u7aef\u53e3&#xff08;\u7528\u4e8e\u9ad8\u6027\u80fd\u901a\u4fe1&#xff09;<\/li>\n<li>-p 8002:8002&#xff1a;Metrics\u7aef\u53e3&#xff08;\u7528\u4e8e\u76d1\u63a7&#xff09;<\/li>\n<li>-v ~\/triton_models:\/models&#xff1a;\u628a\u672c\u5730\u7684\u6a21\u578b\u76ee\u5f55\u6302\u8f7d\u5230\u5bb9\u5668\u91cc<\/li>\n<li>\u6700\u540e\u542f\u52a8Triton\u670d\u52a1\u5668&#xff0c;\u6307\u5b9a\u6a21\u578b\u4ed3\u5e93\u8def\u5f84<\/li>\n<\/ul>\n<h4>4.2 \u68c0\u67e5\u670d\u52a1\u5668\u72b6\u6001<\/h4>\n<p>\u542f\u52a8\u540e&#xff0c;\u4f60\u4f1a\u770b\u5230\u7c7b\u4f3c\u8fd9\u6837\u7684\u8f93\u51fa&#xff1a;<\/p>\n<p>I1230 10:00:00.000000 1 server.cc:592]<br \/>\n&#043;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#043;&#8212;&#8212;&#043;&#8212;&#8212;&#8211;&#043;<br \/>\n| Model            | Version | Status |<br \/>\n&#043;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#043;&#8212;&#8212;&#043;&#8212;&#8212;&#8211;&#043;<br \/>\n| frcrn           | 1     | READY  |<br \/>\n&#043;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#043;&#8212;&#8212;&#043;&#8212;&#8212;&#8211;&#043;<\/p>\n<p>\u8fd9\u8868\u793aFRCRN\u6a21\u578b\u5df2\u7ecf\u52a0\u8f7d\u6210\u529f&#xff0c;\u72b6\u6001\u662fREADY\u3002<\/p>\n<p>\u4f60\u8fd8\u53ef\u4ee5\u901a\u8fc7HTTP\u63a5\u53e3\u68c0\u67e5\u670d\u52a1\u5668\u72b6\u6001&#xff1a;<\/p>\n<p># \u68c0\u67e5\u670d\u52a1\u5668\u5065\u5eb7\u72b6\u6001<br \/>\ncurl -v localhost:8000\/v2\/health\/ready<\/p>\n<p># \u67e5\u770b\u5df2\u52a0\u8f7d\u7684\u6a21\u578b<br \/>\ncurl localhost:8000\/v2\/models<\/p>\n<h4>4.3 \u5e38\u89c1\u542f\u52a8\u95ee\u9898<\/h4>\n<p>\u5982\u679c\u542f\u52a8\u5931\u8d25&#xff0c;\u53ef\u4ee5\u68c0\u67e5\u4ee5\u4e0b\u51e0\u70b9&#xff1a;<\/p>\n<li>\u7aef\u53e3\u51b2\u7a81&#xff1a;\u786e\u4fdd8000\u30018001\u30018002\u7aef\u53e3\u6ca1\u6709\u88ab\u5360\u7528<\/li>\n<li>\u6a21\u578b\u683c\u5f0f\u9519\u8bef&#xff1a;\u68c0\u67e5config.pbtxt\u548cmodel.py\u7684\u8bed\u6cd5<\/li>\n<li>\u6743\u9650\u95ee\u9898&#xff1a;\u786e\u4fddDocker\u6709\u6743\u9650\u8bbf\u95eeGPU<\/li>\n<li>\u5185\u5b58\u4e0d\u8db3&#xff1a;\u5982\u679c\u663e\u5b58\u4e0d\u591f&#xff0c;\u53ef\u4ee5\u51cf\u5c0fmax_batch_size<\/li>\n<h3>5. \u5ba2\u6237\u7aef\u8c03\u7528\u793a\u4f8b<\/h3>\n<p>\u670d\u52a1\u5668\u8dd1\u8d77\u6765\u4e86&#xff0c;\u73b0\u5728\u6211\u4eec\u6765\u5199\u4e2a\u5ba2\u6237\u7aef\u6d4b\u8bd5\u4e00\u4e0b\u3002<\/p>\n<h4>5.1 Python\u5ba2\u6237\u7aef<\/h4>\n<p>\u9996\u5148\u5b89\u88c5Triton\u5ba2\u6237\u7aef\u5e93&#xff1a;<\/p>\n<p>pip install tritonclient[all]<\/p>\n<p>\u7136\u540e\u5199\u4e00\u4e2a\u7b80\u5355\u7684\u5ba2\u6237\u7aef\u811a\u672c&#xff1a;<\/p>\n<p>import numpy as np<br \/>\nimport tritonclient.http as httpclient<br \/>\nimport soundfile as sf<br \/>\nimport librosa<\/p>\n<p>class FRCRNClient:<br \/>\n    &#034;&#034;&#034;FRCRN Triton\u5ba2\u6237\u7aef&#034;&#034;&#034;<\/p>\n<p>    def __init__(self, url&#061;&#034;localhost:8000&#034;):<br \/>\n        self.client &#061; httpclient.InferenceServerClient(url&#061;url)<br \/>\n        self.model_name &#061; &#034;frcrn&#034;<\/p>\n<p>    def preprocess_audio(self, audio_path):<br \/>\n        &#034;&#034;&#034;\u9884\u5904\u7406\u97f3\u9891&#xff1a;\u52a0\u8f7d\u3001\u91cd\u91c7\u6837\u3001\u5f52\u4e00\u5316&#034;&#034;&#034;<br \/>\n        # \u52a0\u8f7d\u97f3\u9891<br \/>\n        audio, sr &#061; librosa.load(audio_path, sr&#061;None)<\/p>\n<p>        # \u91cd\u91c7\u6837\u523016kHz<br \/>\n        if sr !&#061; 16000:<br \/>\n            audio &#061; librosa.resample(audio, orig_sr&#061;sr, target_sr&#061;16000)<\/p>\n<p>        # \u8f6c\u6362\u4e3a\u5355\u58f0\u9053<br \/>\n        if len(audio.shape) &gt; 1:<br \/>\n            audio &#061; librosa.to_mono(audio)<\/p>\n<p>        # \u5f52\u4e00\u5316\u5230[-1, 1]<br \/>\n        audio &#061; audio \/ np.max(np.abs(audio))<\/p>\n<p>        # \u6dfb\u52a0\u6279\u6b21\u7ef4\u5ea6<br \/>\n        audio &#061; audio.astype(np.float32)<br \/>\n        audio &#061; audio.reshape(1, -1)<\/p>\n<p>        return audio<\/p>\n<p>    def denoise(self, audio_path, output_path&#061;&#034;denoised.wav&#034;):<br \/>\n        &#034;&#034;&#034;\u6267\u884c\u964d\u566a&#034;&#034;&#034;<br \/>\n        # \u9884\u5904\u7406\u97f3\u9891<br \/>\n        audio_data &#061; self.preprocess_audio(audio_path)<\/p>\n<p>        # \u51c6\u5907\u8f93\u5165<br \/>\n        inputs &#061; [<br \/>\n            httpclient.InferInput(<br \/>\n                &#034;audio_input&#034;,<br \/>\n                audio_data.shape,<br \/>\n                &#034;FP32&#034;<br \/>\n            )<br \/>\n        ]<br \/>\n        inputs[0].set_data_from_numpy(audio_data)<\/p>\n<p>        # \u51c6\u5907\u8f93\u51fa<br \/>\n        outputs &#061; [<br \/>\n            httpclient.InferRequestedOutput(&#034;audio_output&#034;)<br \/>\n        ]<\/p>\n<p>        # \u53d1\u9001\u8bf7\u6c42<br \/>\n        response &#061; self.client.infer(<br \/>\n            model_name&#061;self.model_name,<br \/>\n            inputs&#061;inputs,<br \/>\n            outputs&#061;outputs<br \/>\n        )<\/p>\n<p>        # \u83b7\u53d6\u7ed3\u679c<br \/>\n        result &#061; response.as_numpy(&#034;audio_output&#034;)<\/p>\n<p>        # \u4fdd\u5b58\u7ed3\u679c<br \/>\n        sf.write(output_path, result[0], 16000)<\/p>\n<p>        print(f&#034;\u964d\u566a\u5b8c\u6210&#xff0c;\u7ed3\u679c\u4fdd\u5b58\u5230: {output_path}&#034;)<br \/>\n        return result<\/p>\n<p>    def batch_denoise(self, audio_paths):<br \/>\n        &#034;&#034;&#034;\u6279\u91cf\u5904\u7406\u591a\u4e2a\u97f3\u9891&#034;&#034;&#034;<br \/>\n        results &#061; []<br \/>\n        for path in audio_paths:<br \/>\n            print(f&#034;\u5904\u7406: {path}&#034;)<br \/>\n            result &#061; self.denoise(path)<br \/>\n            results.append(result)<br \/>\n        return results<\/p>\n<p># \u4f7f\u7528\u793a\u4f8b<br \/>\nif __name__ &#061;&#061; &#034;__main__&#034;:<br \/>\n    # \u521b\u5efa\u5ba2\u6237\u7aef<br \/>\n    client &#061; FRCRNClient()<\/p>\n<p>    # \u5904\u7406\u5355\u4e2a\u97f3\u9891<br \/>\n    client.denoise(&#034;noisy_audio.wav&#034;, &#034;clean_audio.wav&#034;)<\/p>\n<p>    # \u6279\u91cf\u5904\u7406<br \/>\n    # audio_list &#061; [&#034;audio1.wav&#034;, &#034;audio2.wav&#034;, &#034;audio3.wav&#034;]<br \/>\n    # client.batch_denoise(audio_list)<\/p>\n<h4>5.2 \u66f4\u7b80\u5355\u7684\u8c03\u7528\u65b9\u5f0f<\/h4>\n<p>\u5982\u679c\u4f60\u89c9\u5f97\u4e0a\u9762\u7684\u4ee3\u7801\u592a\u590d\u6742&#xff0c;Triton\u8fd8\u63d0\u4f9b\u4e86\u66f4\u7b80\u5355\u7684\u8c03\u7528\u65b9\u5f0f&#xff1a;<\/p>\n<p># \u4f7f\u7528Triton\u7684\u7b80\u6613\u5ba2\u6237\u7aef<br \/>\nfrom tritonclient.utils import *<br \/>\nimport tritonclient.http as httpclient<br \/>\nimport numpy as np<\/p>\n<p># \u8fde\u63a5\u670d\u52a1\u5668<br \/>\ntriton_client &#061; httpclient.InferenceServerClient(url&#061;&#034;localhost:8000&#034;)<\/p>\n<p># \u51c6\u5907\u97f3\u9891\u6570\u636e&#xff08;\u5047\u8bbe\u5df2\u7ecf\u9884\u5904\u7406\u597d\u4e86&#xff09;<br \/>\naudio_data &#061; np.random.randn(1, 16000).astype(np.float32)  # 1\u79d2\u7684\u6d4b\u8bd5\u97f3\u9891<\/p>\n<p># \u6267\u884c\u63a8\u7406<br \/>\ninputs &#061; [httpclient.InferInput(&#034;audio_input&#034;, audio_data.shape, &#034;FP32&#034;)]<br \/>\ninputs[0].set_data_from_numpy(audio_data)<\/p>\n<p>outputs &#061; [httpclient.InferRequestedOutput(&#034;audio_output&#034;)]<\/p>\n<p>results &#061; triton_client.infer(<br \/>\n    model_name&#061;&#034;frcrn&#034;,<br \/>\n    inputs&#061;inputs,<br \/>\n    outputs&#061;outputs<br \/>\n)<\/p>\n<p># \u83b7\u53d6\u7ed3\u679c<br \/>\noutput_data &#061; results.as_numpy(&#034;audio_output&#034;)<br \/>\nprint(f&#034;\u8f93\u51fa\u97f3\u9891\u5f62\u72b6: {output_data.shape}&#034;)<\/p>\n<h4>5.3 \u6027\u80fd\u6d4b\u8bd5<\/h4>\n<p>\u6211\u4eec\u8fd8\u53ef\u4ee5\u6d4b\u8bd5\u4e00\u4e0b\u670d\u52a1\u7684\u6027\u80fd&#xff1a;<\/p>\n<p>import time<\/p>\n<p>def benchmark_client(client, audio_data, num_requests&#061;100):<br \/>\n    &#034;&#034;&#034;\u6027\u80fd\u57fa\u51c6\u6d4b\u8bd5&#034;&#034;&#034;<br \/>\n    latencies &#061; []<\/p>\n<p>    for i in range(num_requests):<br \/>\n        start_time &#061; time.time()<\/p>\n<p>        # \u6267\u884c\u63a8\u7406<br \/>\n        inputs &#061; [httpclient.InferInput(&#034;audio_input&#034;, audio_data.shape, &#034;FP32&#034;)]<br \/>\n        inputs[0].set_data_from_numpy(audio_data)<br \/>\n        outputs &#061; [httpclient.InferRequestedOutput(&#034;audio_output&#034;)]<\/p>\n<p>        _ &#061; client.infer(<br \/>\n            model_name&#061;&#034;frcrn&#034;,<br \/>\n            inputs&#061;inputs,<br \/>\n            outputs&#061;outputs<br \/>\n        )<\/p>\n<p>        latency &#061; (time.time() &#8211; start_time) * 1000  # \u8f6c\u6362\u4e3a\u6beb\u79d2<br \/>\n        latencies.append(latency)<\/p>\n<p>        if (i &#043; 1) % 10 &#061;&#061; 0:<br \/>\n            print(f&#034;\u5df2\u5b8c\u6210 {i &#043; 1}\/{num_requests} \u6b21\u8bf7\u6c42&#034;)<\/p>\n<p>    # \u7edf\u8ba1\u7ed3\u679c<br \/>\n    avg_latency &#061; np.mean(latencies)<br \/>\n    p95_latency &#061; np.percentile(latencies, 95)<\/p>\n<p>    print(f&#034;\\\\n\u6027\u80fd\u6d4b\u8bd5\u7ed3\u679c:&#034;)<br \/>\n    print(f&#034;\u5e73\u5747\u5ef6\u8fdf: {avg_latency:.2f} ms&#034;)<br \/>\n    print(f&#034;P95\u5ef6\u8fdf: {p95_latency:.2f} ms&#034;)<br \/>\n    print(f&#034;QPS: {1000 \/ avg_latency:.2f}&#034;)<\/p>\n<p>    return latencies<\/p>\n<p># \u8fd0\u884c\u6d4b\u8bd5<br \/>\n# test_audio &#061; np.random.randn(1, 16000).astype(np.float32)  # 1\u79d2\u97f3\u9891<br \/>\n# benchmark_client(triton_client, test_audio, num_requests&#061;100)<\/p>\n<h3>6. \u6269\u5c55&#xff1a;\u7ba1\u7406\u591a\u4e2a\u6a21\u578b<\/h3>\n<p>Triton\u6700\u5f3a\u5927\u7684\u5730\u65b9\u5728\u4e8e\u80fd\u7edf\u4e00\u7ba1\u7406\u591a\u4e2a\u6a21\u578b\u3002\u5047\u8bbe\u6211\u4eec\u9664\u4e86FRCRN&#xff0c;\u8fd8\u60f3\u90e8\u7f72\u4e00\u4e2a\u8bed\u97f3\u8bc6\u522b\u6a21\u578b\u548c\u4e00\u4e2a\u8bed\u97f3\u5408\u6210\u6a21\u578b\u3002<\/p>\n<h4>6.1 \u6dfb\u52a0\u65b0\u6a21\u578b<\/h4>\n<p>\u53ea\u9700\u8981\u5728\u6a21\u578b\u4ed3\u5e93\u76ee\u5f55\u4e0b\u521b\u5efa\u65b0\u7684\u6a21\u578b\u6587\u4ef6\u5939&#xff1a;<\/p>\n<p># \u6dfb\u52a0\u8bed\u97f3\u8bc6\u522b\u6a21\u578b<br \/>\nmkdir -p ~\/triton_models\/speech_recognition\/1<br \/>\nmkdir -p ~\/triton_models\/speech_recognition\/config<\/p>\n<p># \u6dfb\u52a0\u8bed\u97f3\u5408\u6210\u6a21\u578b<br \/>\nmkdir -p ~\/triton_models\/speech_synthesis\/1<br \/>\nmkdir -p ~\/triton_models\/speech_synthesis\/config<\/p>\n<p>\u7136\u540e\u4e3a\u6bcf\u4e2a\u6a21\u578b\u51c6\u5907\u5bf9\u5e94\u7684config.pbtxt\u548cmodel.py\u6587\u4ef6\u3002<\/p>\n<h4>6.2 \u7edf\u4e00\u8c03\u7528\u63a5\u53e3<\/h4>\n<p>\u6709\u4e86\u591a\u4e2a\u6a21\u578b\u540e&#xff0c;\u6211\u4eec\u53ef\u4ee5\u521b\u5efa\u4e00\u4e2a\u7edf\u4e00\u7684API\u7f51\u5173&#xff1a;<\/p>\n<p>class AIServiceGateway:<br \/>\n    &#034;&#034;&#034;AI\u670d\u52a1\u7f51\u5173&#xff0c;\u7edf\u4e00\u7ba1\u7406\u591a\u4e2a\u6a21\u578b&#034;&#034;&#034;<\/p>\n<p>    def __init__(self, triton_url&#061;&#034;localhost:8000&#034;):<br \/>\n        self.client &#061; httpclient.InferenceServerClient(url&#061;triton_url)<br \/>\n        self.models &#061; {<br \/>\n            &#034;denoise&#034;: &#034;frcrn&#034;,<br \/>\n            &#034;asr&#034;: &#034;speech_recognition&#034;,<br \/>\n            &#034;tts&#034;: &#034;speech_synthesis&#034;<br \/>\n        }<\/p>\n<p>    def process_pipeline(self, audio_path):<br \/>\n        &#034;&#034;&#034;\u5904\u7406\u6d41\u6c34\u7ebf&#xff1a;\u964d\u566a -&gt; \u8bc6\u522b -&gt; \u5408\u6210&#034;&#034;&#034;<br \/>\n        # 1. \u964d\u566a<br \/>\n        print(&#034;\u6b65\u9aa41: \u8bed\u97f3\u964d\u566a&#034;)<br \/>\n        denoised_audio &#061; self.denoise(audio_path)<\/p>\n<p>        # 2. \u8bed\u97f3\u8bc6\u522b<br \/>\n        print(&#034;\u6b65\u9aa42: \u8bed\u97f3\u8bc6\u522b&#034;)<br \/>\n        text &#061; self.speech_to_text(denoised_audio)<\/p>\n<p>        # 3. \u8bed\u97f3\u5408\u6210&#xff08;\u53ef\u9009&#xff09;<br \/>\n        print(&#034;\u6b65\u9aa43: \u8bed\u97f3\u5408\u6210&#034;)<br \/>\n        synthesized_audio &#061; self.text_to_speech(text)<\/p>\n<p>        return {<br \/>\n            &#034;denoised_audio&#034;: denoised_audio,<br \/>\n            &#034;text&#034;: text,<br \/>\n            &#034;synthesized_audio&#034;: synthesized_audio<br \/>\n        }<\/p>\n<p>    def denoise(self, audio_data):<br \/>\n        &#034;&#034;&#034;\u8c03\u7528FRCRN\u964d\u566a&#034;&#034;&#034;<br \/>\n        # &#8230; \u8c03\u7528FRCRN\u7684\u4ee3\u7801 &#8230;<br \/>\n        pass<\/p>\n<p>    def speech_to_text(self, audio_data):<br \/>\n        &#034;&#034;&#034;\u8c03\u7528\u8bed\u97f3\u8bc6\u522b\u6a21\u578b&#034;&#034;&#034;<br \/>\n        # &#8230; \u8c03\u7528ASR\u6a21\u578b\u7684\u4ee3\u7801 &#8230;<br \/>\n        pass<\/p>\n<p>    def text_to_speech(self, text):<br \/>\n        &#034;&#034;&#034;\u8c03\u7528\u8bed\u97f3\u5408\u6210\u6a21\u578b&#034;&#034;&#034;<br \/>\n        # &#8230; \u8c03\u7528TTS\u6a21\u578b\u7684\u4ee3\u7801 &#8230;<br \/>\n        pass<\/p>\n<p># \u4f7f\u7528\u793a\u4f8b<br \/>\n# gateway &#061; AIServiceGateway()<br \/>\n# result &#061; gateway.process_pipeline(&#034;noisy_audio.wav&#034;)<\/p>\n<h4>6.3 \u6a21\u578b\u7248\u672c\u7ba1\u7406<\/h4>\n<p>Triton\u652f\u6301\u6a21\u578b\u7248\u672c\u7ba1\u7406&#xff0c;\u4f60\u53ef\u4ee5\u540c\u65f6\u90e8\u7f72\u591a\u4e2a\u7248\u672c\u7684\u6a21\u578b&#xff1a;<\/p>\n<p># \u6a21\u578b\u76ee\u5f55\u7ed3\u6784<br \/>\nfrcrn\/<br \/>\n\u251c\u2500\u2500 1\/           # \u7248\u672c1<br \/>\n\u2502   \u2514\u2500\u2500 model.py<br \/>\n\u251c\u2500\u2500 2\/           # \u7248\u672c2&#xff08;\u65b0\u7248\u672c&#xff09;<br \/>\n\u2502   \u2514\u2500\u2500 model.py<br \/>\n\u2514\u2500\u2500 config.pbtxt<\/p>\n<p>\u5728\u5ba2\u6237\u7aef\u8c03\u7528\u65f6&#xff0c;\u53ef\u4ee5\u6307\u5b9a\u7248\u672c\u53f7&#xff1a;<\/p>\n<p># \u8c03\u7528\u7279\u5b9a\u7248\u672c\u7684\u6a21\u578b<br \/>\nresponse &#061; client.infer(<br \/>\n    model_name&#061;&#034;frcrn&#034;,<br \/>\n    model_version&#061;&#034;2&#034;,  # \u6307\u5b9a\u7248\u672c\u53f7<br \/>\n    inputs&#061;inputs,<br \/>\n    outputs&#061;outputs<br \/>\n)<\/p>\n<p>\u5982\u679c\u4e0d\u6307\u5b9a\u7248\u672c\u53f7&#xff0c;Triton\u4f1a\u81ea\u52a8\u4f7f\u7528\u6700\u65b0\u7684\u7248\u672c\u3002<\/p>\n<h3>7. \u751f\u4ea7\u73af\u5883\u90e8\u7f72\u5efa\u8bae<\/h3>\n<p>\u5982\u679c\u4f60\u6253\u7b97\u5728\u751f\u4ea7\u73af\u5883\u4f7f\u7528Triton&#xff0c;\u8fd9\u91cc\u6709\u4e00\u4e9b\u5efa\u8bae&#xff1a;<\/p>\n<h4>7.1 \u6027\u80fd\u4f18\u5316<\/h4>\n<li>\u6279\u5904\u7406\u5927\u5c0f\u8c03\u4f18&#xff1a;<\/li>\n<p># \u5728config.pbtxt\u4e2d\u8c03\u6574<br \/>\ndynamic_batching {<br \/>\n  preferred_batch_size: [4, 8, 16]<br \/>\n  max_queue_delay_microseconds: 100<br \/>\n}<\/p>\n<li>\u4f7f\u7528\u6a21\u578b\u96c6\u6210&#xff1a;<\/li>\n<p># \u521b\u5efa\u6a21\u578b\u6d41\u6c34\u7ebf<br \/>\nname: &#034;audio_pipeline&#034;<br \/>\nplatform: &#034;ensemble&#034;<\/p>\n<p>input [<br \/>\n  {<br \/>\n    name: &#034;audio_input&#034;<br \/>\n    data_type: TYPE_FP32<br \/>\n    dims: [ -1, 1 ]<br \/>\n  }<br \/>\n]<\/p>\n<p>output [<br \/>\n  {<br \/>\n    name: &#034;final_output&#034;<br \/>\n    data_type: TYPE_FP32<br \/>\n    dims: [ -1, 1 ]<br \/>\n  }<br \/>\n]<\/p>\n<p>ensemble_scheduling {<br \/>\n  step [<br \/>\n    {<br \/>\n      model_name: &#034;frcrn&#034;<br \/>\n      model_version: -1<br \/>\n      input_map {<br \/>\n        key: &#034;audio_input&#034;<br \/>\n        value: &#034;audio_input&#034;<br \/>\n      }<br \/>\n      output_map {<br \/>\n        key: &#034;audio_output&#034;<br \/>\n        value: &#034;denoised_audio&#034;<br \/>\n      }<br \/>\n    },<br \/>\n    {<br \/>\n      model_name: &#034;vad&#034;  # \u8bed\u97f3\u6d3b\u52a8\u68c0\u6d4b<br \/>\n      model_version: -1<br \/>\n      input_map {<br \/>\n        key: &#034;audio_input&#034;<br \/>\n        value: &#034;denoised_audio&#034;<br \/>\n      }<br \/>\n      output_map {<br \/>\n        key: &#034;vad_output&#034;<br \/>\n        value: &#034;final_output&#034;<br \/>\n      }<br \/>\n    }<br \/>\n  ]<br \/>\n}<\/p>\n<h4>7.2 \u76d1\u63a7\u4e0e\u65e5\u5fd7<\/h4>\n<li>\u542f\u7528Prometheus\u76d1\u63a7&#xff1a;<\/li>\n<p>docker run &#8211;gpus&#061;all &#8211;rm \\\\<br \/>\n  -p 8000:8000 -p 8001:8001 -p 8002:8002 \\\\<br \/>\n  -v ~\/triton_models:\/models \\\\<br \/>\n  nvcr.io\/nvidia\/tritonserver:22.12-py3 \\\\<br \/>\n  tritonserver &#8211;model-repository&#061;\/models \\\\<br \/>\n  &#8211;metrics-port&#061;8002 \\\\<br \/>\n  &#8211;allow-metrics&#061;true \\\\<br \/>\n  &#8211;allow-gpu-metrics&#061;true<\/p>\n<li>\u67e5\u770b\u76d1\u63a7\u6307\u6807&#xff1a;<\/li>\n<p># \u83b7\u53d6\u6027\u80fd\u6307\u6807<br \/>\ncurl localhost:8002\/metrics<\/p>\n<p># \u4f7f\u7528Prometheus &#043; Grafana\u53ef\u89c6\u5316<\/p>\n<h4>7.3 \u9ad8\u53ef\u7528\u90e8\u7f72<\/h4>\n<p>\u5bf9\u4e8e\u751f\u4ea7\u73af\u5883&#xff0c;\u5efa\u8bae\u4f7f\u7528Kubernetes\u90e8\u7f72&#xff1a;<\/p>\n<p># triton-deployment.yaml<br \/>\napiVersion: apps\/v1<br \/>\nkind: Deployment<br \/>\nmetadata:<br \/>\n  name: triton-server<br \/>\nspec:<br \/>\n  replicas: 3  # 3\u4e2a\u526f\u672c<br \/>\n  selector:<br \/>\n    matchLabels:<br \/>\n      app: triton<br \/>\n  template:<br \/>\n    metadata:<br \/>\n      labels:<br \/>\n        app: triton<br \/>\n    spec:<br \/>\n      containers:<br \/>\n      &#8211; name: triton<br \/>\n        image: nvcr.io\/nvidia\/tritonserver:22.12-py3<br \/>\n        args: [&#034;tritonserver&#034;, &#034;&#8211;model-repository&#061;\/models&#034;]<br \/>\n        ports:<br \/>\n        &#8211; containerPort: 8000<br \/>\n        &#8211; containerPort: 8001<br \/>\n        &#8211; containerPort: 8002<br \/>\n        volumeMounts:<br \/>\n        &#8211; name: models<br \/>\n          mountPath: \/models<br \/>\n        resources:<br \/>\n          limits:<br \/>\n            nvidia.com\/gpu: 1<br \/>\n      volumes:<br \/>\n      &#8211; name: models<br \/>\n        persistentVolumeClaim:<br \/>\n          claimName: models-pvc<\/p>\n<h3>8. \u603b\u7ed3<\/h3>\n<p>\u901a\u8fc7\u8fd9\u4e2a\u6559\u7a0b&#xff0c;\u6211\u4eec\u5b8c\u6210\u4e86FRCRN\u8bed\u97f3\u964d\u566a\u6a21\u578b\u5728NVIDIA Triton\u4e0a\u7684\u90e8\u7f72\u3002\u8ba9\u6211\u4eec\u56de\u987e\u4e00\u4e0b\u5173\u952e\u6b65\u9aa4&#xff1a;<\/p>\n<li>\u7406\u89e3\u4e86Triton\u7684\u4ef7\u503c&#xff1a;\u5b83\u8ba9\u591a\u6a21\u578b\u7ba1\u7406\u53d8\u5f97\u7b80\u5355\u7edf\u4e00<\/li>\n<li>\u51c6\u5907\u4e86FRCRN\u6a21\u578b&#xff1a;\u6309\u7167Triton\u8981\u6c42\u7684\u683c\u5f0f\u7ec4\u7ec7\u6a21\u578b\u6587\u4ef6<\/li>\n<li>\u542f\u52a8\u4e86Triton\u670d\u52a1\u5668&#xff1a;\u4e00\u4e2a\u547d\u4ee4\u5c31\u80fd\u542f\u52a8\u670d\u52a1<\/li>\n<li>\u7f16\u5199\u4e86\u5ba2\u6237\u7aef\u4ee3\u7801&#xff1a;\u5b66\u4f1a\u4e86\u5982\u4f55\u8c03\u7528Triton\u670d\u52a1<\/li>\n<li>\u6269\u5c55\u4e86\u591a\u6a21\u578b\u7ba1\u7406&#xff1a;\u770b\u5230\u4e86Triton\u7ba1\u7406\u591a\u4e2a\u6a21\u578b\u7684\u6f5c\u529b<\/li>\n<p>Triton\u7684\u771f\u6b63\u5a01\u529b\u5728\u4e8e\u5b83\u7684\u6269\u5c55\u6027\u3002\u4eca\u5929\u4f60\u90e8\u7f72\u4e86FRCRN&#xff0c;\u660e\u5929\u5c31\u53ef\u4ee5\u7528\u540c\u6837\u7684\u65b9\u5f0f\u90e8\u7f72\u5176\u4ed6\u4efb\u4f55\u6a21\u578b\u3002\u6240\u6709\u7684\u6a21\u578b\u90fd\u901a\u8fc7\u7edf\u4e00\u7684\u63a5\u53e3\u63d0\u4f9b\u670d\u52a1&#xff0c;\u5927\u5927\u964d\u4f4e\u4e86\u8fd0\u7ef4\u590d\u6742\u5ea6\u3002<\/p>\n<p>\u5982\u679c\u4f60\u5728\u5b9e\u8df5\u8fc7\u7a0b\u4e2d\u9047\u5230\u95ee\u9898&#xff0c;\u6216\u8005\u60f3\u4e86\u89e3\u66f4\u9ad8\u7ea7\u7684\u529f\u80fd&#xff0c;\u6211\u5efa\u8bae&#xff1a;<\/p>\n<li>\u4ece\u7b80\u5355\u5f00\u59cb&#xff1a;\u5148\u90e8\u7f72\u4e00\u4e2a\u6a21\u578b&#xff0c;\u8dd1\u901a\u6574\u4e2a\u6d41\u7a0b<\/li>\n<li>\u9010\u6b65\u4f18\u5316&#xff1a;\u6839\u636e\u5b9e\u9645\u9700\u6c42\u8c03\u6574\u6279\u5904\u7406\u5927\u5c0f\u3001\u5b9e\u4f8b\u6570\u91cf\u7b49\u53c2\u6570<\/li>\n<li>\u76d1\u63a7\u6027\u80fd&#xff1a;\u4f7f\u7528Triton\u81ea\u5e26\u7684\u76d1\u63a7\u5de5\u5177&#xff0c;\u4e86\u89e3\u670d\u52a1\u8fd0\u884c\u72b6\u6001<\/li>\n<li>\u793e\u533a\u652f\u6301&#xff1a;Triton\u6709\u6d3b\u8dc3\u7684\u793e\u533a\u548c\u8be6\u7ec6\u7684\u6587\u6863<\/li>\n<p>\u5e0c\u671b\u8fd9\u4e2a\u6559\u7a0b\u80fd\u5e2e\u4f60\u8fc8\u51fa\u591a\u6a21\u578b\u7edf\u4e00\u7ba1\u7406\u7684\u7b2c\u4e00\u6b65\u3002\u5728\u5b9e\u9645\u9879\u76ee\u4e2d&#xff0c;\u4f60\u53ef\u80fd\u4f1a\u9047\u5230\u5404\u79cd\u6311\u6218&#xff0c;\u4f46\u6709\u4e86Triton\u8fd9\u4e2a\u5f3a\u5927\u7684\u5de5\u5177&#xff0c;\u81f3\u5c11\u6a21\u578b\u90e8\u7f72\u8fd9\u90e8\u5206\u4f1a\u8f7b\u677e\u5f88\u591a\u3002<\/p>\n<hr \/>\n<p>\u83b7\u53d6\u66f4\u591aAI\u955c\u50cf<\/p>\n<p>\u60f3\u63a2\u7d22\u66f4\u591aAI\u955c\u50cf\u548c\u5e94\u7528\u573a\u666f&#xff1f;\u8bbf\u95ee CSDN\u661f\u56fe\u955c\u50cf\u5e7f\u573a&#xff0c;\u63d0\u4f9b\u4e30\u5bcc\u7684\u9884\u7f6e\u955c\u50cf&#xff0c;\u8986\u76d6\u5927\u6a21\u578b\u63a8\u7406\u3001\u56fe\u50cf\u751f\u6210\u3001\u89c6\u9891\u751f\u6210\u3001\u6a21\u578b\u5fae\u8c03\u7b49\u591a\u4e2a\u9886\u57df&#xff0c;\u652f\u6301\u4e00\u952e\u90e8\u7f72\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>FRCRN\u90e8\u7f72\u6559\u7a0b&#xff1a;\u4f7f\u7528NVIDIA Triton\u63a8\u7406\u670d\u52a1\u5668\u7edf\u4e00\u7ba1\u7406\u591a\u6a21\u578b<br \/>\n\u4f60\u662f\u4e0d\u662f\u4e5f\u9047\u5230\u8fc7\u8fd9\u6837\u7684\u70e6\u607c&#xff1f;\u56e2\u961f\u91cc\u90e8\u7f72\u4e86\u597d\u51e0\u4e2aAI\u6a21\u578b&#xff0c;\u6bcf\u4e2a\u6a21\u578b\u90fd\u6709\u81ea\u5df1\u7684\u73af\u5883\u4f9d\u8d56\u3001\u542f\u52a8\u811a\u672c\u548cAPI\u63a5\u53e3&#xff0c;\u7ba1\u7406\u8d77\u6765\u50cf\u4e00\u76d8\u6563\u6c99\u3002\u4eca\u5929\u8981\u90e8\u7f72\u4e00\u4e2a\u8bed\u97f3\u964d\u566a\u6a21\u578b&#xff0c;\u660e\u5929\u8981\u4e0a\u7ebf\u4e00\u4e2a\u56fe\u50cf\u8bc6\u522b\u670d\u52a1&#xff0c;\u540e\u5929\u53ef\u80fd\u53c8\u8981\u52a0\u4e00\u4e2a\u6587\u672c\u751f\u6210\u5de5\u5177\u3002\u6bcf\u6b21\u90fd\u8981\u5355\u72ec\u914d\u7f6e&#xff0c;\u4e0d\u4ec5\u6548\u7387\u4f4e\u4e0b&#xff0c;\u8fd8\u5bb9\u6613\u51fa\u9519\u3002<br \/>\n\u5982\u679c\u4f60\u6b63\u5728\u4e3a\u591a\u6a21\u578b\u7ba1\u7406\u5934\u75bc&amp;<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[9281,9282,9280],"topic":[],"class_list":["post-83056","post","type-post","status-publish","format-standard","hentry","category-server","tag-ai","tag-nvidia-triton","tag-9280"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>FRCRN\u90e8\u7f72\u6559\u7a0b\uff1a\u4f7f\u7528NVIDIA Triton\u63a8\u7406\u670d\u52a1\u5668\u7edf\u4e00\u7ba1\u7406\u591a\u6a21\u578b - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.wsisp.com\/helps\/83056.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"FRCRN\u90e8\u7f72\u6559\u7a0b\uff1a\u4f7f\u7528NVIDIA Triton\u63a8\u7406\u670d\u52a1\u5668\u7edf\u4e00\u7ba1\u7406\u591a\u6a21\u578b - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"FRCRN\u90e8\u7f72\u6559\u7a0b&#xff1a;\u4f7f\u7528NVIDIA Triton\u63a8\u7406\u670d\u52a1\u5668\u7edf\u4e00\u7ba1\u7406\u591a\u6a21\u578b \u4f60\u662f\u4e0d\u662f\u4e5f\u9047\u5230\u8fc7\u8fd9\u6837\u7684\u70e6\u607c&#xff1f;\u56e2\u961f\u91cc\u90e8\u7f72\u4e86\u597d\u51e0\u4e2aAI\u6a21\u578b&#xff0c;\u6bcf\u4e2a\u6a21\u578b\u90fd\u6709\u81ea\u5df1\u7684\u73af\u5883\u4f9d\u8d56\u3001\u542f\u52a8\u811a\u672c\u548cAPI\u63a5\u53e3&#xff0c;\u7ba1\u7406\u8d77\u6765\u50cf\u4e00\u76d8\u6563\u6c99\u3002\u4eca\u5929\u8981\u90e8\u7f72\u4e00\u4e2a\u8bed\u97f3\u964d\u566a\u6a21\u578b&#xff0c;\u660e\u5929\u8981\u4e0a\u7ebf\u4e00\u4e2a\u56fe\u50cf\u8bc6\u522b\u670d\u52a1&#xff0c;\u540e\u5929\u53ef\u80fd\u53c8\u8981\u52a0\u4e00\u4e2a\u6587\u672c\u751f\u6210\u5de5\u5177\u3002\u6bcf\u6b21\u90fd\u8981\u5355\u72ec\u914d\u7f6e&#xff0c;\u4e0d\u4ec5\u6548\u7387\u4f4e\u4e0b&#xff0c;\u8fd8\u5bb9\u6613\u51fa\u9519\u3002 \u5982\u679c\u4f60\u6b63\u5728\u4e3a\u591a\u6a21\u578b\u7ba1\u7406\u5934\u75bc&amp;\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/83056.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2026-07-25T08:10:25+00:00\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"9 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/83056.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/83056.html\",\"name\":\"FRCRN\u90e8\u7f72\u6559\u7a0b\uff1a\u4f7f\u7528NVIDIA Triton\u63a8\u7406\u670d\u52a1\u5668\u7edf\u4e00\u7ba1\u7406\u591a\u6a21\u578b - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2026-07-25T08:10:25+00:00\",\"dateModified\":\"2026-07-25T08:10:25+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/83056.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/83056.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/83056.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"FRCRN\u90e8\u7f72\u6559\u7a0b\uff1a\u4f7f\u7528NVIDIA Triton\u63a8\u7406\u670d\u52a1\u5668\u7edf\u4e00\u7ba1\u7406\u591a\u6a21\u578b\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\",\"url\":\"https:\/\/www.wsisp.com\/helps\/\",\"name\":\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"description\":\"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"contentUrl\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"caption\":\"admin\"},\"sameAs\":[\"http:\/\/wp.wsisp.com\"],\"url\":\"https:\/\/www.wsisp.com\/helps\/author\/admin\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"FRCRN\u90e8\u7f72\u6559\u7a0b\uff1a\u4f7f\u7528NVIDIA Triton\u63a8\u7406\u670d\u52a1\u5668\u7edf\u4e00\u7ba1\u7406\u591a\u6a21\u578b - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.wsisp.com\/helps\/83056.html","og_locale":"zh_CN","og_type":"article","og_title":"FRCRN\u90e8\u7f72\u6559\u7a0b\uff1a\u4f7f\u7528NVIDIA Triton\u63a8\u7406\u670d\u52a1\u5668\u7edf\u4e00\u7ba1\u7406\u591a\u6a21\u578b - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"FRCRN\u90e8\u7f72\u6559\u7a0b&#xff1a;\u4f7f\u7528NVIDIA Triton\u63a8\u7406\u670d\u52a1\u5668\u7edf\u4e00\u7ba1\u7406\u591a\u6a21\u578b \u4f60\u662f\u4e0d\u662f\u4e5f\u9047\u5230\u8fc7\u8fd9\u6837\u7684\u70e6\u607c&#xff1f;\u56e2\u961f\u91cc\u90e8\u7f72\u4e86\u597d\u51e0\u4e2aAI\u6a21\u578b&#xff0c;\u6bcf\u4e2a\u6a21\u578b\u90fd\u6709\u81ea\u5df1\u7684\u73af\u5883\u4f9d\u8d56\u3001\u542f\u52a8\u811a\u672c\u548cAPI\u63a5\u53e3&#xff0c;\u7ba1\u7406\u8d77\u6765\u50cf\u4e00\u76d8\u6563\u6c99\u3002\u4eca\u5929\u8981\u90e8\u7f72\u4e00\u4e2a\u8bed\u97f3\u964d\u566a\u6a21\u578b&#xff0c;\u660e\u5929\u8981\u4e0a\u7ebf\u4e00\u4e2a\u56fe\u50cf\u8bc6\u522b\u670d\u52a1&#xff0c;\u540e\u5929\u53ef\u80fd\u53c8\u8981\u52a0\u4e00\u4e2a\u6587\u672c\u751f\u6210\u5de5\u5177\u3002\u6bcf\u6b21\u90fd\u8981\u5355\u72ec\u914d\u7f6e&#xff0c;\u4e0d\u4ec5\u6548\u7387\u4f4e\u4e0b&#xff0c;\u8fd8\u5bb9\u6613\u51fa\u9519\u3002 \u5982\u679c\u4f60\u6b63\u5728\u4e3a\u591a\u6a21\u578b\u7ba1\u7406\u5934\u75bc&amp;","og_url":"https:\/\/www.wsisp.com\/helps\/83056.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2026-07-25T08:10:25+00:00","author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"9 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/83056.html","url":"https:\/\/www.wsisp.com\/helps\/83056.html","name":"FRCRN\u90e8\u7f72\u6559\u7a0b\uff1a\u4f7f\u7528NVIDIA Triton\u63a8\u7406\u670d\u52a1\u5668\u7edf\u4e00\u7ba1\u7406\u591a\u6a21\u578b - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2026-07-25T08:10:25+00:00","dateModified":"2026-07-25T08:10:25+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/83056.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/83056.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/83056.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"FRCRN\u90e8\u7f72\u6559\u7a0b\uff1a\u4f7f\u7528NVIDIA Triton\u63a8\u7406\u670d\u52a1\u5668\u7edf\u4e00\u7ba1\u7406\u591a\u6a21\u578b"}]},{"@type":"WebSite","@id":"https:\/\/www.wsisp.com\/helps\/#website","url":"https:\/\/www.wsisp.com\/helps\/","name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","description":"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41","name":"admin","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/","url":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","contentUrl":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","caption":"admin"},"sameAs":["http:\/\/wp.wsisp.com"],"url":"https:\/\/www.wsisp.com\/helps\/author\/admin"}]}},"_links":{"self":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/83056","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/comments?post=83056"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/83056\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=83056"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=83056"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=83056"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=83056"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}