【问题标题】:How to edit Azure ML entry or scoring script file once it is deployed in aks or aci在 aks 或 aci 中部署后如何编辑 Azure ML 条目或评分脚本文件
【发布时间】:2021-06-30 19:31:10
【问题描述】:

**我已经在 aci 中部署了模型端点 1 个月,现在我想更改相同模型的入口脚本中的一些内容,那么我如何在不更改 restendpoint 的情况下做到这一点。?

我的条目脚本如下所示:**

SENTIMENT_THRESHOLDS = (0.4, 0.7)
SEQUENCE_LENGTH = 300
def run(data):
try:
    # Pick out the text property of the JSON request.
    # This expects a request in the form of {"text": "some text to score for sentiment"}
    data = json.loads(data)
    prediction = predict(data['text'])
    #Return prediction
    return prediction
except Exception as e:
    error = str(e)
    return error

**现在我想更改变量 SEQUENCE_LENGTH 并用这个入口脚本文件更新 restendpoint **

【问题讨论】:

    标签: azure machine-learning azure-aks azure-machine-learning-service azure-container-instances


    【解决方案1】:

    要重新部署到 ACI,请在注册表中的 Docker 映像上使用 :latest 标签。如果您将映像重新部署到注册表并重新启动 ACI 到指针注册表,它将自动部署新版本/映像。

    如果您只是尝试调试和重新部署,请在本地执行此操作请遵循以下文档。 https://docs.microsoft.com/en-us/azure/machine-learning/how-to-troubleshoot-deployment#debug-locally

    Doc 使用 SDK 更新已部署的 Web 服务。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2022-08-19
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2011-06-14
      • 2021-03-01
      相关资源
      最近更新 更多