OpenCV  4.9.0
Open Source Computer Vision
Functions
Initializeation and Information

Functions

void cv::cann::finalizeAcl ()
 finalize AscendCL. More...
 
int32_t cv::cann::getDevice ()
 Get current Ascend device. More...
 
AscendMat cv::cann::getInputMat (InputArray src, AscendStream &stream)
 Get Ascend matrix object from Input array, upload matrix memory if need. (Non-Blocking call) More...
 
AscendMat cv::cann::getOutputMat (OutputArray dst, int rows, int cols, int type, AscendStream &stream)
 Get Ascend matrix object from Output array, upload matrix memory if need. More...
 
void cv::cann::initAcl ()
 init AscendCL. More...
 
void cv::cann::resetDevice ()
 Clear all context created in current Ascend device. More...
 
void cv::cann::setDevice (int device)
 Choose Ascend npu device. More...
 
void cv::cann::syncOutput (const AscendMat &dst, OutputArray _dst, AscendStream &stream)
 Sync output matrix to Output array, download matrix memory if need. More...
 

Detailed Description

Function Documentation

◆ finalizeAcl()

void cv::cann::finalizeAcl ( )

#include <opencv2/cann.hpp>

finalize AscendCL.

Note
finalizeAcl only can be called once for a process. Call this function after all AscendCL options finished.

◆ getDevice()

int32_t cv::cann::getDevice ( )

#include <opencv2/cann.hpp>

Get current Ascend device.

◆ getInputMat()

AscendMat cv::cann::getInputMat ( InputArray  src,
AscendStream stream 
)

#include <opencv2/cann.hpp>

Get Ascend matrix object from Input array, upload matrix memory if need. (Non-Blocking call)

◆ getOutputMat()

AscendMat cv::cann::getOutputMat ( OutputArray  dst,
int  rows,
int  cols,
int  type,
AscendStream stream 
)

#include <opencv2/cann.hpp>

Get Ascend matrix object from Output array, upload matrix memory if need.

◆ initAcl()

void cv::cann::initAcl ( )

#include <opencv2/cann.hpp>

init AscendCL.

◆ resetDevice()

void cv::cann::resetDevice ( )

#include <opencv2/cann.hpp>

Clear all context created in current Ascend device.

◆ setDevice()

void cv::cann::setDevice ( int  device)

#include <opencv2/cann.hpp>

Choose Ascend npu device.

◆ syncOutput()

void cv::cann::syncOutput ( const AscendMat dst,
OutputArray  _dst,
AscendStream stream 
)

#include <opencv2/cann.hpp>

Sync output matrix to Output array, download matrix memory if need.