Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Huawei Teng support added to OpenCV image processing high frequency interface

2025-01-20 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > IT Information >

Share

Shulou(Shulou.com)12/24 Report--

CTOnews.com, December 12, according to the OpenCV China development team, in order to further speed up OpenCV image processing, the upcoming version of OpenCV 4.9.0 provides Huawei Ascend support for image processing-related high-frequency interfaces.

In addition, on October 17, 2023, the OpenCV community officially accepted Penton + openEuler as one of the operating systems of the continuous integration (Continuous Integration,CI) system, which means that future OpenCV code modifications will be automatically built and tested in the Teng + openEuler environment, ensuring the stability of OpenCV support on openEuler.

According to reports, the image processing interface provided this time is encapsulated in the cannops module of the OpenCV expansion package (opencv_contrib), including image matrix arithmetic operation, channel split and merge, image cropping, flipping, resizing, transpose and other image processing Python and C++ interfaces, with the same processing accuracy as the calculation result of the CPU backend.

OpenCV is an open source cross-platform computer vision library, providing image processing, machine learning, video analysis and other functions, supporting a variety of development languages, multi-platform and multi-type back-end. The image processing module provides matrix arithmetic and logic operation, image processing, video codec and so on, which is widely used in data preprocessing and post-processing in the field of computer vision.

An example of implementing image processing by calling the backend of Teng Teng with CTOnews.com:

In addition to the necessary initialization and de-initialization for Paiteng, users do not need to learn CANN API, but only need to add the cann package name to the original API (API C++ uses the cann namespace) to use PaiTeng computing power.

Import cv2# cann initialize cv2.cann.initAcl () # Select the device number cv2.cann.setDevice (0) # Image processing (take image rotation as an example) img = cv2.imread ('/ path/to/image') # add the cann package name call ret = cv2.cann.rotate (img, 0) cv2.imwrite ('/ path/to/result', ret) # cann to initialize cv2.cann.finalizeAcl ()

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

IT Information

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report