目录

GetComputeNodeInfo

Function Description

Obtains information about the compute node corresponding to the kernel.

Graph execution is essentially the execution on the kernel of each node in the graph. This method can obtain the saved ComputeNodeInfo from KernelContext, which contains information such as InputDesc.

Function Prototype

const ComputeNodeInfo *GetComputeNodeInfo() const

Parameters

None

Return Value

Information about the compute node.

For details about the definition of ComputeNodeInfo, see ComputeNodeInfo.

Restrictions

None

Calling Example

// Assume that KernelContext *context already exists.
auto extend_context = reinterpret_cast<ExtendedKernelContext *>(context);
auto compute_node_info = extend_context->GetComputeNodeInfo();