Span

Applicable Products

For details about the mapping between Ascend AI Processors and Ascend products, see Ascend Product Overview.

Product

Supported

Atlas A3 training products/Atlas A3 inference products

x

Atlas A2 training products/Atlas A2 inference products

√

Atlas 200I/500 A2 inference products

x

Atlas inference products

√

Atlas training products

x

For the Atlas A2 training products/Atlas A2 inference products, only Atlas 800I A2 inference products are supported.

For the Atlas inference products, only the Atlas 300I Duo inference card and Atlas 800 inference server (model 3000) are supported.

Function

Creates a Span.

Prototype

1
Span(const char* spanName, TraceContext& ctx, bool isSampled = true,const char* moduleName = nullptr, bool autoEnd = true)

Parameters

Table 1 Parameters

Parameter

Input/Output

Description

spanName

Input

Span name.

ctx

Input

Trace context.

isSampled

Input

Sampling or not; defaults to true.

moduleName

Input

(Optional) Module name.

autoEnd

Input

Whether to automatically end the trace; defaults to true.

Returns

Returns the current Trace context information.