

本文属于机器翻译版本。若本译文内容与英语原文存在差异，则一律以英文原文为准。

# 推理容器映像


SageMaker Neo 现在为`ml_*`目标提供推理图像 URI 信息。有关更多信息，请参阅 [DescribeCompilationJob](https://docs.amazonaws.cn/sagemaker/latest/APIReference/API_DescribeCompilationJob.html#sagemaker-DescribeCompilationJob-response-InferenceImage)。

根据您的应用场景，将下面提供的推理映像 URI 模板中突出显示的部分替换为相应的值。

## 亚马逊 SageMaker AI XGBoost


```
aws_account_id.dkr.ecr.aws_region.amazonaws.com/xgboost-neo:latest
```

根据*aws\$1region*您使用的替换*aws\$1account\$1id*本页末尾的表格。

## Keras


```
aws_account_id.dkr.ecr.aws_region.amazonaws.com/sagemaker-neo-keras:fx_version-instance_type-py3
```

根据*aws\$1region*您使用的替换*aws\$1account\$1id*本页末尾的表格。

将 *fx\$1version*替换为 `2.2.4`。

将 *instance\$1type* 替换为 `cpu` 或 `gpu`。

## MXNet


------
#### [ CPU or GPU instance types ]

```
aws_account_id.dkr.ecr.aws_region.amazonaws.com/sagemaker-inference-mxnet:fx_version-instance_type-py3
```

根据*aws\$1region*您使用的替换*aws\$1account\$1id*本页末尾的表格。

将 *fx\$1version*替换为 `1.8.0`。

将 *instance\$1type* 替换为 `cpu` 或 `gpu`。

------
#### [ Inferentia1 ]

```
aws_account_id.dkr.ecr.aws_region.amazonaws.com/sagemaker-neo-mxnet:fx_version-instance_type-py3
```

将 *aws\$1region* 替换为 `us-east-1` 或 `us-west-2`。

根据*aws\$1region*您使用的替换*aws\$1account\$1id*本页末尾的表格。

将 *fx\$1version*替换为 `1.5.1`。

将 *`instance_type`*替换为 `inf`。

------

## ONNX


```
aws_account_id.dkr.ecr.aws_region.amazonaws.com/sagemaker-neo-onnx:fx_version-instance_type-py3
```

根据*aws\$1region*您使用的替换*aws\$1account\$1id*本页末尾的表格。

将 *fx\$1version*替换为 `1.5.0`。

将 *instance\$1type* 替换为 `cpu` 或 `gpu`。

## PyTorch


------
#### [ CPU or GPU instance types ]

```
aws_account_id.dkr.ecr.aws_region.amazonaws.com/sagemaker-inference-pytorch:fx_version-instance_type-py3
```

根据*aws\$1region*您使用的替换*aws\$1account\$1id*本页末尾的表格。

*fx\$1version*替换为`1.4``1.5`、`1.6`、`1.7`、、`1.8`、`1.12`、`1.13`、或`2.0`。

将 *instance\$1type* 替换为 `cpu` 或 `gpu`。

------
#### [ Inferentia1 ]

```
aws_account_id.dkr.ecr.aws_region.amazonaws.com/sagemaker-neo-pytorch:fx_version-instance_type-py3
```

将 *aws\$1region* 替换为 `us-east-1` 或 `us-west-2`。

根据*aws\$1region*您使用的替换*aws\$1account\$1id*本页末尾的表格。

将 *fx\$1version*替换为 `1.5.1`。

将 *`instance_type`*替换为 `inf`。

------
#### [ Inferentia2 and Trainium1 ]

```
763104351884.dkr.ecr.aws_region.amazonaws.com/pytorch-inference-neuronx:1.13.1-neuronx-py38-sdk2.10.0-ubuntu20.04
```

将 Inferentia2 *aws\$1region* 替`us-east-2`换为，将 Trainium1 替换为。`us-east-1`

------

## TensorFlow


------
#### [ CPU or GPU instance types ]

```
aws_account_id.dkr.ecr.aws_region.amazonaws.com/sagemaker-inference-tensorflow:fx_version-instance_type-py3
```

根据*aws\$1region*您使用的替换*aws\$1account\$1id*本页末尾的表格。

将 *fx\$1version* 替换为 `1.15.3` 或 `2.9`。

将 *instance\$1type* 替换为 `cpu` 或 `gpu`。

------
#### [ Inferentia1 ]

```
aws_account_id.dkr.ecr.aws_region.amazonaws.com/sagemaker-neo-tensorflow:fx_version-instance_type-py3
```

根据*aws\$1region*您使用的替换*aws\$1account\$1id*本页末尾的表格。请注意，对于实例类型 `inf`，仅支持 `us-east-1` 和 `us-west-2`。

将 *fx\$1version* 替换为 `1.15.0`

将 *instance\$1type*替换为 `inf`。

------
#### [ Inferentia2 and Trainium1 ]

```
763104351884.dkr.ecr.aws_region.amazonaws.com/tensorflow-inference-neuronx:2.10.1-neuronx-py38-sdk2.10.0-ubuntu20.04
```

将 Inferentia2 *aws\$1region* 替`us-east-2`换为，将 Trainium1 替换为。`us-east-1`

------

下表*aws\$1account\$1id*与*aws\$1region*. 使用此表查找应用程序所需的正确推理映像 URI。


| aws\$1account\$1id | aws\$1region | 
| --- | --- | 
| 785573368785 | us-east-1 | 
| 007439368137 | us-east-2 | 
| 710691900526 | us-west-1 | 
| 301217895009 | us-west-2 | 
| 802834080501 | eu-west-1 | 
| 205493899709 | eu-west-2 | 
| 254080097072 | eu-west-3 | 
| 601324751636 | eu-north-1 | 
| 966458181534 | eu-south-1 | 
| 746233611703 | eu-central-1 | 
| 11094859797952 | ap-east-1 | 
| 763008648453 | ap-south-1 | 
| 941853720454 | ap-northeast-1 | 
| 151534178276 | ap-northeast-2 | 
| 925152966179 | ap-northeast-3 | 
| 324986816169 | ap-southeast-1 | 
| 355873309152 | ap-southeast-2 | 
| 474822919863 | cn-northwest-1 | 
| 472730292857 | cn-north-1 | 
| 756306329178 | sa-east-1 | 
| 464438896020 | ca-central-1 | 
| 836785723513 | me-south-1 | 
| 774647643957 | af-south-1 | 
| 275950707576 | il-central-1 | 