python-3.x - 如何使用 Python 从图像中读取文本和文本颜色?
问题描述
我必须阅读文本,但我需要文本的RGB
值。我怎么才能得到它?我正在使用下面的代码段阅读文本。谁能帮我吗?
from PIL import Image
from pytesseract import image_to_string
print(image_to_string(Image.open('images.png')))
解决方案
推荐阅读
- sql - 如何在 Oracle SQL 中将变量设置为 select 语句的结果
- python - python中数据类型“object”和dtype('O')有什么区别
- excel - VBA 找不到值
- postgresql - 当启用行级安全性并且使用 NOT LEAKPROOF 运算符时,PostgreSQL 会忽略 pg_trgm GIN 索引
- .net - 即使等待方法调用(从一个 API 到另一个 API),任务取消异常
- reactjs - 如何在反应本机应用程序中使用 xState 路由导航
- java - 从 Firestore 获取空数组列表
- python - 如何使用 Python 从属性文件中删除最后出现的“=”符号
- python - 如何创建一个包含大括号内的任何字符、整数和符号的正则表达式?
- java - Android Firebase 提醒通知未显示