你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn。
Get-AzureRmCognitiveServicesAccountUsage
获取认知服务帐户的当前使用情况。
警告
截至 2024 年 2 月 29 日,AzureRM PowerShell 模块已正式弃用。 为了确保持续获得支持和更新,建议用户从 AzureRM 迁移到 Az PowerShell 模块。
尽管 AzureRM 模块仍可能正常运行,但它不再维护或受支持,但会根据用户的自由裁量权和风险继续使用任何继续使用模块。 有关过渡到 Az 模块的指导,请参阅我们的迁移资源。
语法
Get-AzureRmCognitiveServicesAccountUsage
[-ResourceGroupName] <String>
[-Name] <String>
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Get-AzureRmCognitiveServicesAccountUsage
[-InputObject] <PSCognitiveServicesAccount>
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Get-AzureRmCognitiveServicesAccountUsage
[-ResourceId] <String>
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
说明
Get-AzureRmCognitiveServicesAccountUsage cmdlet 获取认知服务帐户的当前使用情况。
示例
示例 1
PS C:\> Get-AzureRmCognitiveServicesAccountUsage -ResourceGroupName TestUsages -Name TestCVUsages_Prediction
CurrentValue : 0
Name : CustomVision.Prediction.Transactions
Limit : 10000
Status : Included
Unit : Count
QuotaPeriod : 30.00:00:00
NextResetTime : 0001-01-01T00:00:00Z
示例 2
PS C:\GitHub> $acc = Get-AzureRmCognitiveServicesAccount -ResourceGroupName TestUsages -Name TestCVUsages_Prediction
PS C:\GitHub> Get-AzureRmCognitiveServicesAccountUsage -InputObject $acc
CurrentValue : 0
Name : CustomVision.Prediction.Transactions
Limit : 10000
Status : Included
Unit : Count
QuotaPeriod : 30.00:00:00
NextResetTime : 0001-01-01T00:00:00Z
示例 3
PS C:\GitHub> $acc = Get-AzureRmCognitiveServicesAccount -ResourceGroupName TestUsages -Name TestCVUsages_Prediction
PS C:\GitHub> Get-AzureRmCognitiveServicesAccountUsage -ResourceId $acc.Id
CurrentValue : 0
Name : CustomVision.Prediction.Transactions
Limit : 10000
Status : Included
Unit : Count
QuotaPeriod : 30.00:00:00
NextResetTime : 0001-01-01T00:00:00Z
参数
-DefaultProfile
用于与 Azure 通信的凭据、帐户、租户和订阅。
Type: | IAzureContextContainer |
Aliases: | AzureRmContext, AzureCredential |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-InputObject
认知服务帐户对象。
Type: | PSCognitiveServicesAccount |
Position: | 0 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-Name
认知服务帐户名称。
Type: | String |
Aliases: | CognitiveServicesAccountName, AccountName |
Position: | 1 |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ResourceGroupName
资源组名称。
Type: | String |
Position: | 0 |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ResourceId
认知服务帐户资源 ID。
Type: | String |
Position: | 0 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
输入
参数:InputObject (ByValue)