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语言性能不适合在移动端做图色模拟开发
相关推荐
devilnumber26 分钟前
Java 递归算法 详解 + 核心要点 + 实战运用 + 避坑指南
java·开发语言·算法
大貔貅喝啤酒1 小时前
Python Requests库教程
自动化测试·python·requests库
copyer_xyf2 小时前
LangChain 调用 LLM
后端·python·agent
copyer_xyf2 小时前
Prompt 组织管理
后端·python·agent
asdfg12589632 小时前
JavaBean是什么?怎么理解?有什么用途?
java·开发语言
shimly1234562 小时前
python3 uvicorn 是啥?
python
CTA量化套保3 小时前
期货量化程序 time.sleep 卡死:天勤单线程与 deadline 替代
python·区块链
摇滚侠4 小时前
SpringMVC 入门到实战 文件上传 75-77
java·后端·spring·maven·intellij-idea
GIS数据转换器4 小时前
城市排水生命线安全运行监测平台深度解析
java·运维·人工智能·python·安全·数据挖掘·无人机
贤哥哥yyds4 小时前
GBK转UTF\-8编码自动转换工具 使用文档
python