python语言性能不适合在移动端做图色模拟开发,推荐用lua

python 复制代码
##python			--100次找色用时92120毫秒
from airscript.screen import FindColors
from time import time
t1=time()
for i in range(100):
    p=FindColors("888,888,#000000").rect(0,0,1080,2400).find()
t2=time()
print(f'用时{round((t2-t1)*1000)}毫秒')#	用时92120毫秒
##结论:python语言性能不适合在移动端做图色模拟开发
lua 复制代码
--lua			--100次找色用时3217毫秒
t1=time()
for i=1,100,1 do
    p=findColor({0,0,1080,2400,"888,888,#000000",95})
end
t2=time()
print("用时"..(t2-t1).."毫秒")--		用时3217毫秒


--结论:python语言性能不适合在移动端做图色模拟开发
相关推荐
喵手12 分钟前
Python爬虫零基础入门【第二章:网页基础·第1节】网页是怎么工作的:URL、请求、响应、状态码?
爬虫·python·python爬虫实战·python爬虫工程化实战·python爬虫零基础入门·网页基础
茶本无香27 分钟前
@Scheduled(cron = “0 */5 * * * ?“) 详解
java·定时任务·scheduled
yaonoran29 分钟前
【无标题】
java·开发语言·变量
康小庄35 分钟前
浅谈Java中的volatile关键字
java·开发语言·jvm·spring boot·spring·jetty
vx_bisheyuange37 分钟前
基于SpringBoot的海鲜市场系统
java·spring boot·后端·毕业设计
忧郁的橙子.44 分钟前
26期_01_Pyhton判断语句
python
康康的AI博客44 分钟前
工业数据中台:PLC、SCADA、MES的实时协同架构
java·服务器·网络
快乐小胡!1 小时前
【自动化测试】Selenium选择/定位元素的基本方法
python·selenium·测试工具
それども1 小时前
为什么要加@ResponseBody
java·开发语言·spring boot
一只专注api接口开发的技术猿1 小时前
微服务架构下集成淘宝商品 API 的实践与思考
java·大数据·开发语言·数据库·微服务·架构