You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

AzureML:K-means聚类模型部署Web服务返回空结果问题

K-means聚类推理管道部署为Web服务后返回空结果问题

问题描述

我创建了一个基于K-means算法的数据集聚类推理管道,在Azure机器学习设计器中运行时一切正常,能够正确返回输入数据的聚类分配结果。但将该管道部署为Web服务后,调用服务始终返回空结果。

相关场景说明:

  • 实时端点测试:返回0条数据
  • K-means聚类模型实时推理管道视图
  • Web服务输出结果数据集视图

更新:4/22

在部署日志中发现警告信息,内容随所使用的AksCompute实例模式不同而变化:

  • 开发测试模式:output_name WebServiceOutput0 exists in schema but not in data
  • 生产模式:output_name output1 exists in schema but not in data

已尝试多种方法仍无法获取有效返回数据,已向微软提交支持工单,若得到解决方案会在此更新。

更新:4/24

测试端点时的部署日志如下:

Init: Graph has been loaded
2023-04-24 17:32:43,725 | root | INFO | Users's init has completed successfully
2023-04-24 17:32:43,726 | root | INFO | Skipping middleware: dbg_model_info as it's not enabled.
2023-04-24 17:32:43,726 | root | INFO | Skipping middleware: dbg_resource_usage as it's not enabled.
Found swagger file: /var/azureml-app/swagger.json
Swagger file loaded.
2023-04-24 17:32:43,733 | root | INFO | Scoring timeout is found from os.environ: 60000 ms
2023-04-24 17:32:50,235 | root | INFO | 200
127.0.0.1 - - [24/Apr/2023:17:32:50 +0000] "GET /swagger.json HTTP/1.0" 200 3301 "-" "-"
2023-04-24 17:32:53,910 | root | INFO | Scoring Timer is set to 60.0 seconds
Handling http request - Start:
2023-04-24 17:32:53,911 studio.azureml.designer.serving.dagengine.request_handler INFO       |   Run: is_classic = False, with_details = False, verbose = True
2023-04-24 17:32:53,911 studio.core          INFO       |   Pre-processing - Start:
2023-04-24 17:32:53,911 studio.core          INFO       |   Pre-processing - End with 0.0001s elapsed.
2023-04-24 17:32:53,912 studio.core          INFO       |   Processing - Start:
2023-04-24 17:32:53,932 studio.core          INFO       |   Processing - End with 0.0207s elapsed.
2023-04-24 17:32:53,933 studio.core          INFO       |   Post-processing - Start:
2023-04-24 17:32:53,933 studio.azureml.designer.serving.dagengine.processor WARNING    |   |   output_name WebServiceOutput0 exists in schema but not in data
2023-04-24 17:32:53,934 studio.core          INFO       |   Post-processing - End with 0.0006s elapsed.
2023-04-24 17:32:53,934 studio.core          INFO       Handling http request - End with 0.0235s elapsed.
2023-04-24 17:32:53,940 studio.azureml.designer.serving.dagengine.request_handler DEBUG      Run: output data(raw) = {"Results": {}}
2023-04-24 17:32:53,941 | root | INFO | run() output is HTTP Response
2023-04-24 17:32:53,941 | root | INFO | 200
127.0.0.1 - - [24/Apr/2023:17:32:53 +0000] "POST /score?verbose=true HTTP/1.0" 200 15 "-" "-"
2023-04-24 17:33:04,283 | root | INFO | 200
127.0.0.1 - - [24/Apr/2023:17:33:04 +0000] "GET /swagger.json HTTP/1.0" 200 3301 "-" "-"
2023-04-24 17:33:11,437 | root | INFO | 200
127.0.0.1 - - [24/Apr/2023:17:33:11 +0000] "GET /swagger.json HTTP/1.0" 200 3301 "-" "-"
2023-04-24 17:33:12,932 | root | INFO | Scoring Timer is set to 60.0 seconds
2023-04-24 17:33:12,932 studio.core          INFO       Handling http request - Start:
2023-04-24 17:33:12,932 studio.azureml.designer.serving.dagengine.request_handler INFO       |   Run: is_classic = False, with_details = False, verbose = True
2023-04-24 17:33:12,932 studio.core          INFO       |   Pre-processing - Start:
2023-04-24 17:33:12,933 studio.core          INFO       |   Pre-processing - End with 0.0001s elapsed.
2023-04-24 17:33:12,933 studio.core          INFO       |   Processing - Start:
2023-04-24 17:33:12,949 studio.core          INFO       |   Processing - End with 0.0163s elapsed.
2023-04-24 17:33:12,949 studio.core          INFO       |   Post-processing - Start:
2023-04-24 17:33:12,949 studio.azureml.designer.serving.dagengine.processor WARNING    |   |   output_name WebServiceOutput0 exists in schema but not in data
2023-04-24 17:33:12,949 studio.core          INFO       |   Post-processing - End with 0.0001s elapsed.
2023-04-24 17:33:12,949 studio.core          INFO       Handling http request - End with 0.0170s elapsed.
2023-04-24 17:33:12,949 studio.azureml.designer.serving.dagengine.request_handler DEBUG      Run: output data(raw) = {"Results": {}}
2023-04-24 17:33:12,950 | root | INFO | run() output is HTTP Response
2023-04-24 17:33:12,950 | root | INFO | 200
127.0.0.1 - - [24/Apr/2023:17:33:12 +0000] "POST /score?verbose=true HTTP/1.0" 200 15 "-" "-"
2023-04-24 17:42:24,397 | root | INFO | 200
127.0.0.1 - - [24/Apr/2023:17:42:24 +0000] "GET /swagger.json HTTP/1.0" 200 3301 "-" "-"

内容的提问来源于stack exchange,提问作者Simon

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.07.24 07:54:53