aclrtRandomNumAsync

Applicable Products

Product

Supported

Ascend 950PR / Ascend 950DT

☓

Atlas A3 training products / Atlas A3 inference products

√

Atlas A2 training products / Atlas A2 inference products

√

Atlas 200I/500 A2 inference products

☓

Atlas inference products

☓

Atlas training products

☓

Function

Delivers and executes a random number generation task. This is an asynchronous API.

Prototype

1
aclError aclrtRandomNumAsync(const aclrtRandomNumTaskInfo *taskInfo, const aclrtStream stream, void *reserve)

Parameters

Parameter

Input/Output

Description

taskInfo

Input

Random number generation task information. For details about the type definition, see aclrtRandomNumTaskInfo.

stream

Input

Stream that executes the random number generation task. For details about the type definition, see aclrtStream.

reserve

Input

Reserved. Currently, the value is fixed at NULL.

Returns

0 on success; otherwise, failure. For details, see aclError.

API Call Example

For the API call example, see Random Number Generation.