---
title: 函数：allocator_create_desc
description: "| 产品 | 是否支持 |"
url: https://www.hiascend.com/document/detail/zh/canncommercial/latest/API/runtimeapi/aclpythondevg_01_0974.html
sourcePath: /source/zh/canncommercial/900/API/runtimeapi/aclpythondevg_01_0974.html
indexId: d4d7738f07c6321e91be09c5e0541f543b520e7065254198bfeccc429845463971
---
# 函数：allocator_create_desc

#### 产品支持情况

| 产品 | 是否支持 |
| --- | --- |
| Atlas 350 加速卡 | √ |
| Atlas A3 训练系列产品 / Atlas A3 推理系列产品 | √ |
| Atlas A2 训练系列产品 / Atlas A2 推理系列产品 | √ |
| Atlas 训练系列产品 | √ |
| Atlas 推理系列产品 | √ |
| Atlas 200I/500 A2 推理产品 | √ |


#### 功能说明

创建aclrtAllocatorDesc类型的数据，表示Allocator描述信息，主要用于注册回调函数。


#### 函数原型

- C函数原型
  1 aclrtAllocatorDesc aclrtAllocatorCreateDesc()

- python函数
  1 desc = acl.rt.allocator_create_desc()


#### 参数说明

无


#### 返回值说明

| 返回值 | 说明 |
| --- | --- |
| desc | int。 返回aclrtAllocatorDesc类型的指针地址，表示成功。 返回NULL，表示失败。 |
