当前位置:网站首页>将opencv 图片转换为字节的方式
将opencv 图片转换为字节的方式
2022-04-23 12:58:00 【图像处理大大大大大牛啊】
1.
out = io.BytesIO()
np.save(out, img)
out.seek(0)
# 读取
out.read()
2.
success, encoded_image = cv2.imencode('.png', img)
content = encoded_image.tobytes()
版权声明
本文为[图像处理大大大大大牛啊]所创,转载请带上原文链接,感谢
https://blog.csdn.net/qq_26696715/article/details/124360889
边栏推荐
- Kubernets Getting started tutoriel
- XinChaCha Trust SSL Organization Validated
- mysql8安装
- [daily question] chessboard question
- Recommended website for drawing result map
- PHP generates JSON to process Chinese
- Use compressorjs to compress pictures, optimize functions, and compress pictures in all formats
- Subscribe to Alibaba demo send business messages
- Summary of JVM knowledge points - continuously updated
- leetcode:437. Path sum III [DFS selected or not selected?]
猜你喜欢
Unlock openharmony technology day! The annual event is about to open!
Introduction to servlet listener & filter
SSM框架系列——Junit单元测试优化day2-3
The accuracy and speed are perfectly balanced, and the latest image segmentation SOTA model is released!!!
mysql8安装
[csnote] ER diagram
【csnote】ER图
将新增和编辑的数据同步更新到列表
产品开发都应该知道的8个网站,增强工作体验
[Blue Bridge Cup] April 17 provincial competition brushing training (the first three questions)
随机推荐
Trier les principales utilisations de l'Agent IP réseau
数据库中的日期时间类型
Van uploader upload picture implementation process, using native input to upload pictures
World Book Day: I'd like to recommend these books
(1) Openjuterpyrab comparison scheme
21 天学习MongoDB笔记
Image attribute of input: type attribute of fashion cloud learning -h5
Mysql8 installation
将新增和编辑的数据同步更新到列表
Record some NPM related problems (messy records)
leetcode:437. Path sum III [DFS selected or not selected?]
Kubernetes 入门教程
STM32 is connected to the motor drive, the DuPont line supplies power, and then the back burning problem
Plato farm - a game of farm metauniverse with Plato as the goal
Subscribe to Alibaba demo send business messages
Hanlp word splitter (via spark)
PHP generates JSON to process Chinese
Kubernetes 入門教程
Use of Presto date function
Unlock openharmony technology day! The annual event is about to open!