当前位置:网站首页>How to convert opencv pictures to bytes
How to convert opencv pictures to bytes
2022-04-23 13:01:00 【Image processing Daniel】
1.
out = io.BytesIO()
np.save(out, img)
out.seek(0)
# Read
out.read()
2.
success, encoded_image = cv2.imencode('.png', img)
content = encoded_image.tobytes()
版权声明
本文为[Image processing Daniel]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204231258096849.html
边栏推荐
- Date time type in database
- MySQL supports IP access
- mysql8安装
- Complete project data of UAV apriltag dynamic tracking landing based on openmv (LabVIEW + openmv + apriltag + punctual atom four axes)
- 98. Error s.e.errormvcautoconfiguration $staticview reported by freemaker framework: cannot render error page for request
- Golang implements MD5, sha256 and bcrypt encryption
- 21 天学习MongoDB笔记
- CVPR 2022 & ntire 2022 | the first transformer for hyperspectral image reconstruction
- SSM框架系列——Junit单元测试优化day2-3
- After the data of El table is updated, the data in the page is not updated this$ Forceupdate() has no effect
猜你喜欢
Use compressorjs to compress pictures, optimize functions, and compress pictures in all formats
Importerror after tensorflow installation: DLL load failed: the specified module cannot be found, and the domestic installation is slow
mysql8安装
Record a website for querying compatibility, string Replaceall() compatibility error
Date time type in database
云原生KubeSphere部署Redis
[csnote] ER diagram
Use source insight to view and edit source code
Recovering data with MySQL binlog
mysql支持ip访问
随机推荐
SQL exercise question 1
STM32 tracking based on open MV
There is no need to crack the markdown editing tool typora
Software testing weekly (issue 68): the best way to solve difficult problems is to wait and see the changes and push the boat with the current.
three. JS text ambiguity problem
SSM框架系列——Junit单元测试优化day2-3
The project file '' has been renamed or is no longer in the solution, and the source control provider associated with the solution could not be found - two engineering problems
拥抱机器视觉新蓝海,冀为好望开启数字经济发展新“冀”遇
Connect orcale
async void 导致程序崩溃
Homomorphic encryption technology learning
The use of dcast and melt in R language is simple and easy to understand
Mysql8 installation
Golang implements MD5, sha256 and bcrypt encryption
Important knowledge of transport layer (interview, retest, final)
leetcode-791. Custom string sorting
SSM框架系列——注解开发day2-2
CGC: contractual graph clustering for community detection and tracking
PC starts multiple wechat at one time
About the 'enum' enumeration type and structure.