OpenCV  4.9.0
Open Source Computer Vision
Classes | Public Member Functions | Static Public Member Functions | Friends | List of all members
cv::cann::AscendStream Class Reference

In AscendCL Stream(AscendStream) is a task queue. Stream is used to manage the parallelism of tasks. The tasks inside a Stream are executed sequentially, that is, the Stream executes sequentially according to the sent tasks; the tasks in different Streams are executed in parallel. More...

#include <opencv2/cann.hpp>

Classes

class  Impl
 Warpper of CANN streams. More...
 

Public Member Functions

 AscendStream ()
 
void addTensorHolder (const std::shared_ptr< uchar > &holder)
 
void waitAscendEvent (const cv::cann::AscendEvent &event)
 blocks the current CPU thread until event trigger. More...
 
void waitForCompletion ()
 blocks the current CPU thread until all operations in the stream are complete. More...
 

Static Public Member Functions

static AscendStreamNull ()
 return default AscendStream object for default Acl stream. More...
 

Friends

class AscendStreamAccessor
 
class DefaultDeviceInitializer
 

Detailed Description

In AscendCL Stream(AscendStream) is a task queue. Stream is used to manage the parallelism of tasks. The tasks inside a Stream are executed sequentially, that is, the Stream executes sequentially according to the sent tasks; the tasks in different Streams are executed in parallel.

All Non-blocking functions should pass parameter stream, These function returns immediately after the task is submitted. Caller should wait stream until completion.

Blocking functions implicityly use the default stream, and synchronize stream before function return.

See also
cuda::Stream

Constructor & Destructor Documentation

◆ AscendStream()

cv::cann::AscendStream::AscendStream ( )

Member Function Documentation

◆ addTensorHolder()

void cv::cann::AscendStream::addTensorHolder ( const std::shared_ptr< uchar > &  holder)

◆ Null()

static AscendStream& cv::cann::AscendStream::Null ( )
static

return default AscendStream object for default Acl stream.

◆ waitAscendEvent()

void cv::cann::AscendStream::waitAscendEvent ( const cv::cann::AscendEvent event)

blocks the current CPU thread until event trigger.

◆ waitForCompletion()

void cv::cann::AscendStream::waitForCompletion ( )

blocks the current CPU thread until all operations in the stream are complete.

Friends And Related Function Documentation

◆ AscendStreamAccessor

friend class AscendStreamAccessor
friend

◆ DefaultDeviceInitializer

friend class DefaultDeviceInitializer
friend

The documentation for this class was generated from the following file: