你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn。
Face List Operations - Get Large Face List Training Status
若要检查“大型人脸列表”训练状态已完成或仍在进行。 大型人脸列表训练是由“训练大型人脸列表”触发的异步操作。
训练时间取决于大型人脸列表中的人脸条目数。 对于 1,000,000 张人脸,它可能以秒为单位,或者最多半小时。
GET {endpoint}/face/{apiVersion}/largefacelists/{largeFaceListId}/training
URI 参数
名称 | 在 | 必需 | 类型 | 说明 |
---|---|---|---|---|
api
|
path | True |
string |
API 版本 |
endpoint
|
path | True |
string uri |
支持的认知服务终结点 (协议和主机名,例如:https://{resource-name}.cognitiveservices.azure.com) 。 |
large
|
path | True |
string |
有效字符是小写字母、数字或“-”或“_”,最大长度为 64。 Regex pattern: |
响应
名称 | 类型 | 说明 |
---|---|---|
200 OK |
成功调用将返回大型人脸列表的训练状态。 |
|
Other Status Codes |
意外的错误响应。 Headers x-ms-error-code: string |
安全性
Ocp-Apim-Subscription-Key
Azure AI 人脸订阅的密钥。
Type:
apiKey
In:
header
AADToken
Azure Active Directory OAuth2 流
Type:
oauth2
Flow:
accessCode
Authorization URL:
https://api.example.com/oauth2/authorize
Token URL:
https://api.example.com/oauth2/token
Scopes
名称 | 说明 |
---|---|
https://cognitiveservices.azure.com/.default |
示例
Get Training Status of LargeFaceList
Sample Request
GET {endpoint}/face/v1.1-preview.1/largefacelists/your_large_face_list_id/training
Sample Response
{
"status": "notStarted",
"createdDateTime": "2024-03-05T11:07:58.371Z",
"lastActionDateTime": "2024-03-05T11:07:58.371Z",
"lastSuccessfulTrainingDateTime": "2024-03-05T11:07:58.371Z",
"message": null
}
定义
名称 | 说明 |
---|---|
Face |
错误对象。 有关人脸服务返回的错误代码和消息的综合详细信息,请参阅以下链接: https://aka.ms/face-error-codes-and-messages。 |
Face |
包含错误详细信息的响应。 |
Operation |
长时间运行的操作的状态。 |
Training |
容器的训练结果 |
FaceError
错误对象。 有关人脸服务返回的错误代码和消息的综合详细信息,请参阅以下链接: https://aka.ms/face-error-codes-and-messages。
名称 | 类型 | 说明 |
---|---|---|
code |
string |
服务器定义的一组错误代码中的一个。 |
message |
string |
错误的用户可读表示形式。 |
FaceErrorResponse
包含错误详细信息的响应。
名称 | 类型 | 说明 |
---|---|---|
error |
错误对象。 |
OperationStatus
长时间运行的操作的状态。
名称 | 类型 | 说明 |
---|---|---|
failed |
string |
操作失败。 |
notStarted |
string |
操作未启动。 |
running |
string |
操作仍在运行。 |
succeeded |
string |
操作成功。 |
TrainingResult
容器的训练结果
名称 | 类型 | 说明 |
---|---|---|
createdDateTime |
string |
一个组合的 UTC 日期和时间字符串,用于描述人员组、大型人员组或大型人脸列表的创建时间。 |
lastActionDateTime |
string |
当组未成功训练时,描述人员组、大型人员组或大型人脸列表的上次修改时间的组合 UTC 日期和时间字符串可能为 null 值。 |
lastSuccessfulTrainingDateTime |
string |
组合的 UTC 日期和时间字符串,用于描述人员组、大型人员组或大型人脸列表的上次成功训练时间。 |
message |
string |
在训练失败时显示失败消息 (训练成功时省略) 。 |
status |
容器的训练状态。 |